tag:blogger.com,1999:blog-44673365571739285762024-03-02T00:52:27.119-08:00001101001put the Attention to the code'sAnonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.comBlogger24125tag:blogger.com,1999:blog-4467336557173928576.post-33743250041399991062016-01-18T20:05:00.001-08:002016-01-18T20:05:10.340-08:00Why We Need PCTFREE instead of PCTUSED at Index ?<div dir="ltr" style="text-align: left;" trbidi="on">
<span style="font-family: Trebuchet MS, sans-serif;"><br /></span>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiTBpNUBYMO4g1N-M6SD1_tJVZoRp3N3GUoObbY4W9kYnQdHScoIyieFWPbbofzsF7xZ9JDHdeqy4eYk2la-Q3xrrpjAAJMk085eD37coMY2hUZDKkqfPMoS-sHBTCvYLXYGyYaH2A5Qd8/s1600/oracle-y-lupa1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="121" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiTBpNUBYMO4g1N-M6SD1_tJVZoRp3N3GUoObbY4W9kYnQdHScoIyieFWPbbofzsF7xZ9JDHdeqy4eYk2la-Q3xrrpjAAJMk085eD37coMY2hUZDKkqfPMoS-sHBTCvYLXYGyYaH2A5Qd8/s320/oracle-y-lupa1.jpg" width="320" /></a></div>
<pre style="box-sizing: border-box;"><span style="color: #404040; font-family: Trebuchet MS, sans-serif;"><span style="line-height: 16.5px; white-space: pre-wrap;">
</span></span></pre>
<pre style="box-sizing: border-box;"><span style="color: #404040; font-family: Trebuchet MS, sans-serif;"><span style="line-height: 16.5px; white-space: pre-wrap;">
</span></span></pre>
<pre style="box-sizing: border-box;"><span style="color: #404040; font-family: Trebuchet MS, sans-serif;"><span style="line-height: 16.5px; white-space: pre-wrap;">Basically, a table is a "heap". We stick data WHERE EVER. an index is a structure, we have to stick data where it belongs.
When we take an index block off of the free list -- it is "empty". We will then totally fill it up until we have to split it. It only goes back onto the free list when it is empty again. We cannot put a block on the freelist unless it is empty -- the fact that the INDEX IS A STRUCTURE, prevents us from sticking just any data on the block. Only data that can go onto that block can go there.
It is just "not a heap". </span></span></pre>
</div>
Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-67865966183732331942016-01-18T03:57:00.002-08:002016-01-18T03:59:36.749-08:00Oracle Performance Tuning Best Advice #1<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg9yotQLLyDDQb3Bi3y8KQHQk2hAt2Exi484wVqGx2-g3v24stHfT2qF0dkOH3wRTBke8SrUkeHPeEMItbVGWs7qrSokpJ24Kjuo0R4RhFEnXx2ydsXmSuvbKHTk1HKallkgTT4IOi_8-U/s1600/Oracle+ASNS.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="121" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg9yotQLLyDDQb3Bi3y8KQHQk2hAt2Exi484wVqGx2-g3v24stHfT2qF0dkOH3wRTBke8SrUkeHPeEMItbVGWs7qrSokpJ24Kjuo0R4RhFEnXx2ydsXmSuvbKHTk1HKallkgTT4IOi_8-U/s320/Oracle+ASNS.jpg" width="320" /></a></div>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;"><b>The first important advance in Oracle optimization technology follows from a simple mathematical observation:</b></span><br />
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;"><br /></span>
<br />
<div>
<div>
<b><span style="font-family: "trebuchet ms" , sans-serif; font-size: large;">You can't extrapolate detail from an aggregate.</span></b></div>
</div>
<div>
<b><span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;"><br /></span></b></div>
<div>
<div>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;">Here's a puzzle to demonstrate my point. Imagine that I told you that a collection of 1,000 rocks contains 999 grey rocks and one special rock that's been painted bright red. The collection weighs 1,000 pounds. Now, answer the following question: "How much does the red rock weigh?" If your answer is, "I know that the red rock weighs one pound," then, whether you realize it or not, you've told a lie. You don't know that the red rock weighs one pound. With the information you've been given, you can't know. If your answer is, "I assume that the red rock weighs one pound," then you're too generous in what you're willing to assume. Such an assumption puts you at risk of forming</span></div>
<div>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;">conclusions that are incorrect—perhaps even stunningly incorrect.</span></div>
</div>
<div>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;"><br /></span></div>
<div>
<div>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;">The correct answer is that the red rock can weigh virtually any amount between zero and 1,000 pounds. The only thing limiting the low end of the weight is the definition of how many atoms must be present in order for a thing to be called a rock. Once we define how small a rock can be, then we've defined the high end of our answer. It is 1,000 pounds minus the weight of 999 of the smallest possible rocks. The red rock can weigh virtually anything between zero and a thousand pounds. Answering with any more precision is wrong unless you happen to be very lucky. But being very lucky at games like this is a skill that can be neither learned nor taught, nor repeated with acceptable</span></div>
<div>
<span style="font-family: "trebuchet ms" , sans-serif; font-size: xx-small;">reliability.</span></div>
</div>
</div>
Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com7tag:blogger.com,1999:blog-4467336557173928576.post-66305716597783379402014-03-10T19:09:00.001-07:002014-03-10T19:10:20.454-07:00Detect Gap on Oracle Data Guard 11gR2<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZcnp3d6WZhzyntg-_Y_0WHt1JpUVGD4lugbdzIbJxn2ZUQhGy7XrMfrp5NL1cH2SSR7_z3_45m1g8hULZdWPAqw_zShyphenhyphenAALe6no42aWJj3YM123aW9wBaDk_8zak8hQRq_gvcBZpOjns/s1600/oracle-y-lupa1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZcnp3d6WZhzyntg-_Y_0WHt1JpUVGD4lugbdzIbJxn2ZUQhGy7XrMfrp5NL1cH2SSR7_z3_45m1g8hULZdWPAqw_zShyphenhyphenAALe6no42aWJj3YM123aW9wBaDk_8zak8hQRq_gvcBZpOjns/s1600/oracle-y-lupa1.jpg" height="121" width="320" /></a></div>
<br />
<br />
Gap can occur if LNS is unable to keep pace and the log buffer is recycled before the redo can be transmitted to the standby.<br />
<br />
so how can we detect gap on our Dataguard environment?<br />
some people use this method.<br />
<br />
<blockquote class="tr_bq">
SQL> archive log list;</blockquote>
<blockquote class="tr_bq">
SQL> select max(sequence#) from v$archived_log;</blockquote>
<blockquote class="tr_bq">
SQL> select sequence#, archived, applied from v$archived_log where applied='YES' order by 1;</blockquote>
<br />
Oracle Data Guard provide us with a simple view to detect a gap. we just need to query to that views.<br />
<blockquote class="tr_bq">
SQL> select * v$archive_gap;</blockquote>
<br />
if there's no row selected, you have no gap in your oracle data guard.<br />
don't forget to check your alert log<br />
<blockquote class="tr_bq">
tail -10000f "your alert.log location" </blockquote>
</div>
Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-34035608451029950252013-12-18T19:24:00.001-08:002013-12-19T09:22:56.713-08:00Manually Resolving Gaps - Oracle Data Guard 11gR2<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiGMRLHfL2v_UsE6i_nOWL7bkeCqzIl0U4ia8U4eQSCuDKHWURQB1HeKY5Q5eJZDqMCAnszNufZT3YjYEXEKDQFyGMD_aPI3xAE5afcD2yHzdwYs7L2Kt0OuahNPyFB0-XpiKM3w2IGQeI/s1600/oracle-y-lupa1.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="75" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiGMRLHfL2v_UsE6i_nOWL7bkeCqzIl0U4ia8U4eQSCuDKHWURQB1HeKY5Q5eJZDqMCAnszNufZT3YjYEXEKDQFyGMD_aPI3xAE5afcD2yHzdwYs7L2Kt0OuahNPyFB0-XpiKM3w2IGQeI/s200/oracle-y-lupa1.jpg" width="200" /></a></div>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>for simplicity, Gap is a range of archived redo logs that were created at a time when the standby database was not available to receive them.</b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>in many pratices it happen because the network problems.</b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif;"><b><span style="font-size: x-small;"><br /></span>
<span style="font-size: x-small;">We have 3 method to resolving this problem. i'll dispatch it to two main methods,</span></b></span><br />
<br />
<ol style="text-align: left;">
<li><span style="font-family: Verdana, sans-serif; font-size: x-small;"><b>Manually resolving</b></span></li>
<li><span style="font-family: Verdana, sans-serif; font-size: x-small;"><b>Automatic resolving : Using log switched and FAL configuration</b></span></li>
</ol>
<div>
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><br /></span></div>
<div style="text-align: left;">
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>1. start with detecting gaps in the redo logs by querying the v$archive_gap</b></span><br />
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> select * from v$archive_gap;</span></blockquote>
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">thread# low_sequence# high_sequence#<br />-------- ---------------- ------------------<br /> 1 30 34 </span></blockquote>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b> the output indicates our standby database is currently missing log files from sequence 30 to</b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b> 34.</b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif;"><b><span style="font-size: x-small;"><br /></span>
<span style="font-size: x-small;">2. issue following statement on primary database to locate the archived redo log files. assuming </span></b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b> the local archive destination on primary is LOG_ARCHIVE_DEST_1</b></span><br />
<blockquote class="tr_bq">
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><span style="color: #660000;">SQL> select name from v$archived_log where thread#=1 and dest_id=1 and sequence# between 30 and 34;</span> </span></blockquote>
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">name<br />----------------------------------</span></blockquote>
<blockquote class="tr_bq">
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><span style="color: #660000;">/u02/oraarchive/DB01/arch_t1_s30.dbf</span><span style="color: #660000;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><span style="color: #660000;">/u02/oraarchive/DB01/arch_t1_s31.dbf</span><span style="color: #660000;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><span style="color: #660000;">/u02/oraarchive/DB01/arch_t1_s32.dbf</span><span style="color: #660000;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><span style="color: #660000;">/u02/oraarchive/DB01/arch_t1_s33.dbf</span><span style="color: #660000;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><span style="color: #660000;">/u02/oraarchive/DB01/arch_t1_s34.dbf</span> </span></blockquote>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>3. stop the automatic recovery (MRP) of the data guard</b></span><br />
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database recover managed standby database cancel;</span></blockquote>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>4. transfer manually the archived log files shown on the step 2 to standby database</b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>5. register that archived log files on standby database</b></span><br />
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database register logfile '/u02/oraarchive/DB01/arch_t1_s30.dbf';</span> </blockquote>
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database register logfile '/u02/oraarchive/DB01/arch_t1_s31.dbf';</span> </blockquote>
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database register logfile '/u02/oraarchive/DB01/arch_t1_s32.dbf';</span> </blockquote>
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database register logfile '/u02/oraarchive/DB01/arch_t1_s33.dbf';</span> </blockquote>
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database register logfile '/u02/oraarchive/DB01/arch_t1_s34.dbf';</span> </blockquote>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>6. put the standby database into automatic recovery managed mode</b></span><br />
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> alter database recover managed standby database disconnect from session;</span></blockquote>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>7. verify that the gap gets resolved on standby database</b></span><br />
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> select sequence#, applied from v$archived_log order by sequence#;</span> </blockquote>
<br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>now you figure it out, that your archived log files (ARCLs) has been synchronize with your primary database. as a DBA you must take a notice at log using this SQL statement</b></span><br />
<blockquote class="tr_bq">
<span style="color: #660000; font-family: Verdana, sans-serif; font-size: x-small;">SQL> select message from v$dataguard_status where severity like 'Warning';</span></blockquote>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>also on your alert.log</b></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="color: #cc0000; font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>hope it will make your day easier.</b></span><br />
<span style="color: #cc0000; font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="color: #cc0000; font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b><br /></b></span>
<span style="color: #cc0000; font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>Best Regards,</b></span><br />
<span style="color: #cc0000; font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><b>Dev Yudh</b></span><br />
<br />
<br />
<br /></div>
</div>
Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com2tag:blogger.com,1999:blog-4467336557173928576.post-74735568334137240452012-05-22T00:26:00.000-07:002012-05-22T00:26:44.456-07:00Arsitektur Database Oracle (2)<div dir="ltr" style="text-align: left;" trbidi="on">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>Background Proses</u></b></span><br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgt7xGHHtZkCrUff-HnFvup1J5AqZViwy46a2toJgMYyKbn1G7sMTPWA5LmK88WDUsPPqKif1U2KV8FaGtH8VdQcuId_5zJ1ZuitpWRPehw8Jki8Hw9QFLPIUWBoox6-ups5M40RA5PRws/s1600/Background+Proses.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="241" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgt7xGHHtZkCrUff-HnFvup1J5AqZViwy46a2toJgMYyKbn1G7sMTPWA5LmK88WDUsPPqKif1U2KV8FaGtH8VdQcuId_5zJ1ZuitpWRPehw8Jki8Hw9QFLPIUWBoox6-ups5M40RA5PRws/s400/Background+Proses.JPG" width="400" /></a></div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Untuk memaksimalkan kinerja dan untuk mengakomodasi kepentingan banyak user, sistem Multiproses Oracle menggunakan proses yang disebut background process, proses-proses yang ada disini berfungsi sebagai penjembatan antara Instance (SGA & PGA) dengan database (datafiles, control files, redo log files). Sistem oracle dapat mempunyai banyak background process, tergantung dari konfigurasinya. Background process tersebut adalah sebagai berikut:</span><br />
<br />
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Database Writer (DBWR)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Log Writer (LGWR)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Checkpoint (CKPT)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">System Monitor (SMON)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Process Monitor (PMON)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Archiver (ARCH)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Recoverer (RECO)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Lock (LCKn)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Snapshot Refresh (SNPn)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Shared Server (Snnn)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Dispatcher (Dnnn)</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Parallel Query (Pnnn)</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Proses PMON dan SMON berfungsi untuk me-reclaim sumber daya database yang tidak dibutuhkan lagi oleh seorang user.</span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>PMON (Process Monitor)</u></b></span></div>
<div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">me-Clean up hubungan yang diputuskan secara tidak normal</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">me-Rollback transaksi yang belum di commit</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">me-Release locking yang dipegang oleh suatu proses yang terminated</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Membebaskan sumber daya SGA (Memori SGA) yang dialokasikan pada proses yang gagal</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Me-restart proses server shared yang gagal dan men-dispatch proses-prosesnya.</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>SMON (System Monitor)</u></b></span></div>
</div>
<div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Melakukan recovery instance secara otomatis.</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">me-Reclaim space yang digunakan oleh Temporary segment yang tidak digunakan lagi</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Melakukan merge free space area pada datafile.</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Empat Mandatory Process</span></div>
</div>
<div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">PMON, SMON, DBWR dan LGWR adalah proses mandatory yang harus dijalankan pada suatu instance Oracle. sementara proses lain nya optional</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">PMON, SMON, DBWR dan LGWR tidak bisa dikendalikan dengan mengubah parameter inisialisasi</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Jika ada salah satu dari empat proses yang gagal, instance akan crash dan harus direstart.</span></div>
</div>
<br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiGY5vkLuf_v3NPyvCGW4Yav-KI7hUI9BJJ8LLUk6k6vN_Qhwtron5xKOp8ova-_mWtsLIuJxY_BMIhbfBKo9zSdFRAALw7_-dFngceBmsGWK941rCcHq93b0z5-q3ih1YPLaCijjzJTpo/s1600/Proses+Leckon.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="258" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiGY5vkLuf_v3NPyvCGW4Yav-KI7hUI9BJJ8LLUk6k6vN_Qhwtron5xKOp8ova-_mWtsLIuJxY_BMIhbfBKo9zSdFRAALw7_-dFngceBmsGWK941rCcHq93b0z5-q3ih1YPLaCijjzJTpo/s400/Proses+Leckon.JPG" width="400" /></a></div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>Proses RECO, LCKn, Pnnn dan SNPn</u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">RECO, LCKn, Pnnn, dan SNPn akan dicreate ketika menggunakan salah satu Add On Option.</span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Proses</span><br />
<br />
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Reco me-resolce kegagalan yang terlibat dalam suatu transaksi terdistribusi</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">LCKn melakukan interinstance locking pada suatu sistem server paralel</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Pnnn menyediakan query paralel, pembuatan index paralel, loading data paralel, dan kemampuan CREATE TABLE AS SELECT paralel.</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">SNPn melakukan refresh secara otomatis dari snapshots (table replikasi read-only). Proses tersebut juga akan bertanggung jawab pada antrian pekerjaan server dan antrian replikasi.</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Options</span></div>
<div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Paralel Query Option adalah suatu licensed product yang terpisah</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Procedural Option dibutuhkan untuk snapshots. hal itu termasuk dalam Oracle7 Server</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Distributed Option dibutuhkan untuk transaksi terdistribusi. Option ini adalah licensed product yang terpisah.</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">repilcation Option adalah suatu licensed product yang terpisah.</span></li>
</ul>
</div>
<br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>Proses User</u></b></span><br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhEFdMwdIE6gKJkUppKaVZlLRf4nu6cxX3_nUm1e7KoNke8AJFJUtgu8VY_HU69Dma_0o5IesZaKalyp8orHNuMyyRvSFBQzOeOm9Q4FQUbODYtKfNFflA9QCPvm2BK-Ov89QXAiED20dY/s1600/Proses+User.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="287" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhEFdMwdIE6gKJkUppKaVZlLRf4nu6cxX3_nUm1e7KoNke8AJFJUtgu8VY_HU69Dma_0o5IesZaKalyp8orHNuMyyRvSFBQzOeOm9Q4FQUbODYtKfNFflA9QCPvm2BK-Ov89QXAiED20dY/s400/Proses+User.JPG" width="400" /></a></div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Suatu proses user digunakan ketika seorang user menjalankan suatu program aplikasi. proses User:</span><br />
<br />
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Menjalankan tool / application atas pertimbangan client. contohnya Server Manager, Oracle Forms dan Pro*C.</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">mem-pass SQL ke proses server untuk mendapatkan hasil..</span></li>
</ul>
<br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>Proses Server</u></b></span><br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhv8FXwLpYRKde_TWgOIHv3-hOXUdpHalDKXYf1yS_Zbvc6dhq75tzUefRVre1EQ06xqLpoRDihQK0EKxrqbZv9KB-YOyzSr9JP_6Al6m1BkKoBQoe_Y692laKAgi8ADJPF_aR5xgSsXrA/s1600/Proses+Server.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="300" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhv8FXwLpYRKde_TWgOIHv3-hOXUdpHalDKXYf1yS_Zbvc6dhq75tzUefRVre1EQ06xqLpoRDihQK0EKxrqbZv9KB-YOyzSr9JP_6Al6m1BkKoBQoe_Y692laKAgi8ADJPF_aR5xgSsXrA/s400/Proses+Server.JPG" width="400" /></a></div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">sebelum data dapat diakses, sebuah proses server harus menempatkan data terlebih dahulu ke Database Buffer Cache. Untuk memproses perintah SQL, proses server akan menggunakan shared memory dalam SGA.</span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b>Task Proses Server</b></span><br />
<br />
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Melakukan parsing dan mengeksekusi perintah SQL</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">membaca blok data dari disk ke buffer database (Database buffer cache) shared di SGA</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">mengembalikan hasil dari perintah SQL ke proses USer.</span></li>
</ul>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgC_rJ0WJT-jWp66SBdpv01QN86uswKUV5WjYT16UWqSPoIQRpM0W02EiIRJDunqNRcO1YMPzFudKnYH0ltX46Nmr3lYE-QMqu14ye3RKFPOZdtAHEXIQX144WIB9Ggzlc3KrFDxt55R3c/s1600/Tak+Server.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgC_rJ0WJT-jWp66SBdpv01QN86uswKUV5WjYT16UWqSPoIQRpM0W02EiIRJDunqNRcO1YMPzFudKnYH0ltX46Nmr3lYE-QMqu14ye3RKFPOZdtAHEXIQX144WIB9Ggzlc3KrFDxt55R3c/s1600/Tak+Server.JPG" /></a></div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">asa</span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span><br />
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-58896615639462984272012-05-21T23:39:00.000-07:002012-05-21T23:39:06.680-07:00Arsitektur Database Oracle (1)<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiNmWcWs4ACbKc0H-YAACNoY936SrHiPqHY-GsIUEF1EEIpkRHr-nhNcmgWebEbQQOtqfUOkoCDD-W8baHnmpSP_wBmZZnHSOQFwH1NM3P-tJjY53jN8iukAYemfdWNNJ5W4n6Hw9VmvJg/s1600/Arsitektur+Database+Oracle.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><img border="0" height="240" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiNmWcWs4ACbKc0H-YAACNoY936SrHiPqHY-GsIUEF1EEIpkRHr-nhNcmgWebEbQQOtqfUOkoCDD-W8baHnmpSP_wBmZZnHSOQFwH1NM3P-tJjY53jN8iukAYemfdWNNJ5W4n6Hw9VmvJg/s400/Arsitektur+Database+Oracle.JPG" width="400" /></span></a></div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Arsitektur Database Oracle terdiri dari 2 bagian:</span><br />
<br />
<ul style="text-align: left;">
<li><b><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Instance Database</span></b></li>
<li><b><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Database</span></b></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Instance database adalah segala hal yang berhubungan dengan Memory.</span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Sedangkan Database adalah bentuk Physical dari database oracle, dimana terdapat 3 bagian, yakni: Datafiles, Controlfiles dan Redo logfiles.</span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<b><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Instance Database Structure</span></b></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Instance database terdiri dari blok besar SGA (Shared/System Global Area) dan PGA (Private Global Area).</span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Blok Database Instance.</span></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://docs.oracle.com/cd/E11882_01/server.112/e10713/img/cncpt325.gif" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><img border="0" height="320" src="http://docs.oracle.com/cd/E11882_01/server.112/e10713/img/cncpt325.gif" width="318" /></span></a></div>
<div class="separator" style="clear: both; text-align: center;">
<i><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">from docs.oracle.com</span></i></div>
<div class="separator" style="clear: both; text-align: center;">
<i><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></i></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Di dalam SGA Terdapat : </span></div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Mandatory: Shared Pool, Database Buffer Cache, Redo Log Buffer, Streams Pool </span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Optional : Large Pool dan Java Pool</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Jadi, SGA adalah kumpulan (group) dari struktur shared memory yang memuat data dan informasi pengendali untuk suatu Sistem Basisdata Oracle. SGA harus selalu berada di dalam memori yang non-paged atau non-swapped. jika banyak user yang terhubung bersamaan, maka data pada SGA akan di shared diantara user-user tersebut. Ini mengapa SGA banyak diartikan sebagai (Shared Global Area).</span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<b><u><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Shared Pool</span></u></b></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqj0H1EKGdFqmWbOOvqbf8LlrLna_1FlS5IoD0Pb_BjC5WhAuJdbCAV2YolS7c8lgvtruS6Q6eFb9DgZx1UX1O2Rmfd_Y4XFa0CQLRJMqTJFi05TYAHLCb3bA6HGrPi5hIOL4aD2J5N8U/s1600/Shared+Pool.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><img border="0" height="137" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqj0H1EKGdFqmWbOOvqbf8LlrLna_1FlS5IoD0Pb_BjC5WhAuJdbCAV2YolS7c8lgvtruS6Q6eFb9DgZx1UX1O2Rmfd_Y4XFa0CQLRJMqTJFi05TYAHLCb3bA6HGrPi5hIOL4aD2J5N8U/s320/Shared+Pool.JPG" width="320" /></span></a></div>
<div class="separator" style="clear: both; text-align: center;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Shared Pool adalah suatu bagian dari SGA yang memuat konstruksi shared SQL Area dan Data Dictionary Cache.</span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /><b>** Shared SQL Area</b>: adalah bagian dari SGA yang berisi segala macam sintaks SQL yang pernah dilakukan atau di eksekusi oleh USER. Setiap shared SQL area mengandung informasi yang digunakan untuk menjalankan suatu perintah SQL tunggal. proses-proses yang berjalan akan mengeksekusi perintah-perintah SQL identik yang informasinya di share. suatu perintah SQL ditempatkan pada suatu shared SQL Area berdasarkan pada suatu algoritma hashing yang diterapkan pada perintah tersebut. oleh karena itu, hanya perintah-perintah yang sama seluruhnya yang akan dialokasikan ke lokasi memori yang sama. bisa juga disebut Library Cache</span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b>** Private SQL Area</b>: adalah bagian dari PGA yang berisi segala sintaks Private SQLS (Explicit cursor SQLs) yang dilakukan di tiap session.</span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">beda dari keduanya adalah, Shared SQL Area dilakukan pada arsitektur multi-threaded dimana yang menangani proses session adalah SGA, sedangkan untuk Private SQL Area adalah bila sebuah session dijalankan pada sebuah arsitektur Dedicated (diambil alih oleh PGA = Private Global Area)</span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b>** Data Dictionary Cache</b></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Data Dictionary merupakan suatu kumpulan tabel dan view basisdata yang mengandung referensi informasi tentang basis data, struktur, dan user. data yang disimpan dalam data dictionary adalah sebagai berikut:</span></div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Nama dari semua tabel dan views dalam basis data</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Nama dan tipe data dari kolom dalam tabel basis data</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Privileges dari semua user Oracle</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b>Content Shared Pool</b></span></div>
<div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Teks perintah SQL atau PL/SQL</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Hasil parsing dari perintah SQL atau PL/SQL</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Rencana eksekusi dari perintah SQL atau PL/SQL</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Data Dictionary cache yang mengandung baris dari informasi data dictionary</span></li>
</ul>
</div>
<br />
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b>Jadi, bila seorang user login ke database atau aplikasi yang terhubung ke database, dan melakukan eksekusi. maka SQL sintaks tersebut pertama kali akan diakses oleh Shared Pool ini.</b> Meskipun sebelumnya, pada saat dia eksekusi SQL sintaks akan di cek dulu user tersebut login dari arsitektur multi-threaded (ditangani langsung SGA) atau dedicated (ditangani oleh PGA).</span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>Database Buffer Cache</u></b></span></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi69VVf52n7-wL-hb7KHK4-YIO7_It-LfibNrLhj8EwEOXYBbgppANdfDJIeSjocfMMP8-h-mVE5RkaggOEfPyy_kr2jh__lW9kkGfEtJL2YmsGY9gNZ08u9nGScQk4d5pg-2mOlFmyN_8/s1600/Database+Buffer+Cache.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="135" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi69VVf52n7-wL-hb7KHK4-YIO7_It-LfibNrLhj8EwEOXYBbgppANdfDJIeSjocfMMP8-h-mVE5RkaggOEfPyy_kr2jh__lW9kkGfEtJL2YmsGY9gNZ08u9nGScQk4d5pg-2mOlFmyN_8/s320/Database+Buffer+Cache.JPG" width="320" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Database buffer cache adalah bagian dari SGA yang berfungsi untuk menyimpan copy dari blog data yang dibaca dari disk. semua user yang terhubung ke sistem memperoleh sharing untuk mengakses database buffer cache.</span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div class="separator" style="clear: both; text-align: left;">
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Pengaksesan Data</span></div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<ul style="text-align: left;">
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Cache Miss : Terjadi pada saat pertama kali seorang User mengakses suatu bagian data, proses harus meng-copy data dari disk ke cache sebelum mengakses nya.</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Cache Hit : Terjadi ketika sebuah proses mengakses bagian data yang sudah ada di cache, proses tersebut dapat membaca data dari memori secara langsung.</span></li>
</ul>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">sebuah pengaksesan data melalui cache hit akan berlangsung lebih cepat daripada pengaksesan data melalui suatu cache miss. karena cache memiliki keterbatasan ruang, maka semua data pada disk tidak dapat dimasukkan dalam cache. Ketika cache penug, subsekuen cache misalnya akan memberikan intruksi untuk menuliskan data yang sudah ada di cache ke disk untuk membuat tempat bagi data baru. dan akan menyebabkan suatu cache miss (karena data baru di tulis ke disk tuk pertama kali).</span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><br /></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b>Database Buffer Cache akan dikunjungi jika seorang user melakukan query SQL setelah melewati Shared Pool.</b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><br /></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u>Redo Log Buffer</u></b></span></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjI85Z40QOdTG7WmItbYy_HI1ssTbOD2k7oOfi-7TOVlhH31-vRJrzDOo75lCI0AA0G4Bnvo3TxD28MQTDyy-ulnVcMqj2ZRNSriXXFNWTDQU03kHehXEjuYsu9qBjU6BMKa5m9UJ5DjOM/s1600/Redo+Log+Buffer.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="156" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjI85Z40QOdTG7WmItbYy_HI1ssTbOD2k7oOfi-7TOVlhH31-vRJrzDOo75lCI0AA0G4Bnvo3TxD28MQTDyy-ulnVcMqj2ZRNSriXXFNWTDQU03kHehXEjuYsu9qBjU6BMKa5m9UJ5DjOM/s320/Redo+Log+Buffer.JPG" width="320" /></a></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Redo Log Buffer adalah suatu circular buffer yang berisi informasi tentang perubahan-perubahan yang terjadi di database, tugas Redo Log Buffer adalah:</span></div>
<div>
<ul>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">Mencatat semua perubahan yang terjadi pada basis data dalam redo log buffer</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">merekonstruksi perubahanyang terjadi pada entry-entry basis data dan rollback segment pada saat terjadi proses recovery</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">dapat di bypass menggunakan kata kunci UNRECOVERABLE pada perintah CREATE TABLE dan CREATE INDEX</span></li>
<li><span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;">dapat di bypass oleh ORACLE data Loader</span></li>
</ul>
</div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;"><b><u><br /></u></b></span></div>
<div>
<span style="font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif; font-size: x-small;"><b><u><br /></u></b></span></div>
<br />
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com2tag:blogger.com,1999:blog-4467336557173928576.post-9232663055963026552011-12-04T08:02:00.001-08:002011-12-04T08:03:04.469-08:00Keutamaan Puasa Tasu’a Dan ‘Asyura [9 & 10 Muharram]<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Bismillah…</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Hari ‘Asyura di depan mata. Siapkan ilmu untuk mengahadapinya. Jangan seperti Syiah Rafidhah atau Sufiyah! Jadilah Anda seorang muslim pejuang sunnah an-nabawiyah. Selamat menyimak, semoga Allah mudahkan kita tuk mengamalkannya…</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
<em>Oleh: Asy Syaikh Muhammad bin Shalih Al Utsaimin</em><i><br /></i><br />[Di dalam kitab beliau Riyadhus Shalihin, Al-Imam An-Nawawi -rahimahullah- membawakan tiga buah hadits yang berkenaan dengan puasa sunnah pada bulan Muharram, yaitu puasa hari Asyura / Asyuro (10 Muharram) dan Tasu’a (9 Muharram)]</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Hadits yang Pertama</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
عن ابن عباس رَضِيَ اللَّهُ عَنهُ أن رَسُول اللَّهِ صَلَّى اللَّهُ عَلَيهِ وَسَلَّم صام يوم عاشوراء وأمر بصيامه. مُتَّفّقٌ عَلَيهِ</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Dari Ibnu Abbas -radhiyallahu ‘anhuma-, “Bahwa Rasulullah shallallahu ‘alaihi wasallam berpuasa pada hari ‘Asyura dan memerintahkan untuk berpuasa padanya”. (Muttafaqun ‘Alaihi).</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Hadits yang Kedua</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
عن أبي قتادة رَضِيَ اللَّهُ عَنهُ أن رَسُول اللَّهِ صَلَّى اللَّهُ عَلَيهِ وَسَلَّم سئل عن صيام يوم عاشوراء فقال: ((يكفر السنة الماضية)) رَوَاهُ مُسلِمٌ.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Dari Abu Qatadah -radhiyallahu ‘anhu-, bahwa Rasulullah shallallahu ‘alaihi wasallam ditanya tentang puasa hari ‘Asyura. Beliau menjawab, “(Puasa tersebut) Menghapuskan dosa satu tahun yang lalu”. (HR. Muslim)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Hadits yang Ketiga</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
وعن ابن عباس رَضِيَ اللَّهُ عَنهُما قال، قال رَسُول اللَّهِ صَلَّى اللَّهُ عَلَيهِ وَسَلَّم: ((لئن بقيت إلى قابل لأصومن التاسع)) رَوَاهُ مُسلِمٌ.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Dari Ibnu Abbas -radhiyallahu ‘anhuma- beliau berkata: “Rasulullah shallallahu ‘alaihi wasallam bersabda, “Apabila (usia)ku sampai tahun depan, maka aku akan berpuasa pada (hari) kesembilan” (HR. Muslim)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“Rasulullah shallallahu ‘alaihi wasallam ditanya tentang puasa pada hari ‘Asyura, beliau menjawab, ‘Menghapuskan dosa setahun yang lalu’, ini pahalanya lebih sedikit daripada puasa Arafah (yakni menghapuskan dosa setahun sebelum serta sesudahnya –pent). Bersamaan dengan hal tersebut, selayaknya seorang berpuasa ‘Asyura (10 Muharram) disertai dengan (sebelumnya, ed.) Tasu’a (9 Muharram). Hal ini karena Nabi shallallahu ‘alaihi wasallam bersabda, ‘Apabila (usia)ku sampai tahun depan, maka aku akan berpuasa pada yang kesembilan’, maksudnya berpuasa pula pada hari Tasu’a.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
<strong>Penjelasan</strong><br />Rasulullah shallallahu ‘alaihi wasallam memerintahkan untuk berpuasa pada hari sebelum maupun setelah ‘Asyura [1] dalam rangka menyelisihi orang-orang Yahudi karena hari ‘Asyura –yaitu 10 Muharram- adalah hari di mana Allah selamatkan Musa dan kaumnya, dan menenggelamkan Fir’aun dan para pengikutnya. Dahulu orang-orang Yahudi berpuasa pada hari tersebut sebagai syukur mereka kepada Allah atas nikmat yang agung tersebut. Allah telah memenangkan tentara-tentaranya dan mengalahkan tentara-tentara syaithan, menyelamatkan Musa dan kaumnya serta membinasakan Fir’aun dan para pengikutnya. Ini merupakan nikmat yang besar.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Oleh karena itu, setelah Nabi shallallahu ‘alaihi wasallam tinggal di Madinah, beliau melihat bahwa orang-orang Yahudi berpuasa pada hari ‘Asyura [2]. Beliau pun bertanya kepada mereka tentang hal tersebut. Maka orang-orang Yahudi tersebut menjawab, “Hari ini adalah hari di mana Allah telah menyelamatkan Musa dan kaumnya, serta celakanya Fir’aun serta pengikutnya. Maka dari itu kami berpuasa sebagai rasa syukur kepada Allah”. Rasulullah shallallahu ‘alaihi wasallam berkata, “Kami lebih berhak terhadap Musa daripada kalian”.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Kenapa Rasulullah mengucapkan hal tersebut? Karena Nabi dan orang–orang yang bersama beliau adalah orang-orang yang lebih berhak terhadap para nabi yang terdahulu. Allah berfirman,</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
إِنَّ أَوْلَى النَّاسِ بِإِبْرَاهِيمَ لَلَّذِينَ اتَّبَعُوهُ وَهَذَا النَّبِيُّ وَالَّذِينَ آَمَنُوا وَاللَّهُ وَلِيُّ الْمُؤْمِنِينَ</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“Sesungguhnya orang yang paling berhak dengan Ibrahim adalah orang-orang yang mengikutinya dan nabi ini (Muhammad), serta orang-orang yang beriman, dan Allah-lah pelindung semua orang-orang yang beriman”. (Ali Imran: 68)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Maka Rasulullah shallallahu ‘alaihi wasallam adalah orang yang paling berhak terhadap Nabi Musa daripada orang-orang Yahudi tersebut, dikarenakan mereka kafir terhadap Nabi Musa, Nabi Isa dan Muhammad. Maka beliau shallallahu ‘alaihi wasallam berpuasa ‘Asyura dan memerintahkan manusia untuk berpuasa pula pada hari tersebut. Beliau juga memerintahkan untuk menyelisihi Yahudi yang hanya berpuasa pada hari ‘Asyura, dengan berpuasa pada hari kesembilan atau hari kesebelas beriringan dengan puasa pada hari kesepuluh (’Asyura), atau ketiga-tiganya. [3]</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Oleh karena itu sebagian ulama seperti Ibnul Qayyim dan yang selain beliau menyebutkan bahwa puasa ‘Asyura terbagi menjadi tiga keadaan:</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
1. Berpuasa pada hari ‘Asyura dan Tasu’ah (9 Muharram), ini yang paling afdhal.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
2. Berpuasa pada hari ‘Asyura dan tanggal 11 Muharram, ini kurang pahalanya daripada yang pertama. [4]</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
3. Berpuasa pada hari ‘Asyura saja, sebagian ulama memakruhkannya karena Nabi shallallahu ‘alaihi wasallam memerintahkan untuk menyelisihi Yahudi, namun sebagian ulama yang lain memberi keringanan (tidak menganggapnya makhruh). [5]</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Wallahu a’lam bish shawab.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
(Sumber: Syarh Riyadhis Shalihin karya Asy-Syaikh Muhammad bin Shalih Al-Utsaimin terbitan Darus Salam – Mesir, diterjemahkan Abu Umar Urwah Al-Bankawy, muraja’ah dan catatan kaki: Al-Ustadz Abu Abdillah Muhammad Rifai)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
CATATAN KAKI:</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
[1] Adapun hadits yang menyebutkan perintah untuk berpuasa setelahnya (11 Asyura’) adalah dha’if (lemah). Hadits tersebut berbunyi:</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
صوموا يوم عاشوراء و خالفوا فيه اليهود صوموا قبله يوما و بعده يوما . -</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“Puasalah kalian hari ‘Asyura dan selisihilah orang-orang yahudi padanya (maka) puasalah sehari sebelumnya dan sehari setelahnya. (HR. Ahmad dan Al Baihaqy. Didhaifkan oleh As Syaikh Al-Albany di Dha’iful Jami’ hadits no. 3506)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Dan berkata As Syaikh Al Albany – Rahimahullah- di Silsilah Ad Dha’ifah Wal Maudhu’ah IX/288 No. Hadits 4297: Penyebutan sehari setelahnya (hari ke sebelas. pent) adalah mungkar, menyelisihi hadits Ibnu Abbas yang shahih dengan lafadz:</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“لئن بقيت إلى قابل لأصومن التاسع” .</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“Jika aku hidup sampai tahun depan tentu aku akan puasa hari kesembilan”</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Lihat juga kitab Zaadul Ma’ad 2/66 cet. Muassasah Ar-Risalah Th. 1423 H. dengan tahqiq Syu’aib Al Arnauth dan Abdul Qadir Al Arna’uth.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
لئن بقيت لآمرن بصيام يوم قبله أو يوم بعده . يوم عاشوراء) .-</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“Kalau aku masih hidup niscaya aku perintahkan puasa sehari sebelumnya (hari Asyura) atau sehari sesudahnya” ((HR. Al Baihaqy, Berkata Al Albany di As-Silsilah Ad-Dha’ifah Wal Maudhu’ah IX/288 No. Hadits 4297: Ini adalah hadits mungkar dengan lafadz lengkap tersebut.))</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
[2] Padanya terdapat dalil yang menunjukkan bahwa penetapan waktu pada umat terdahulu pun menggunakan bulan-bulan qamariyyah (Muharram s/d Dzulhijjah, Pent.) bukan dengan bulan-bulan ala Eropa (Jan s/d Des). Karena Rasulullah shalallahu ‘alaihi wasallam mengabarkan bahwa hari ke sepuluh dari Muharram adalah hari di mana Allah membinasakan Fir’aun dan pengikutnya dan menyelamatkan Musa dan pengikutnya. (Syarhul Mumthi’ VI.)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
[3] Untuk puasa di hari kesebelas haditsnya adalah dha’if (lihat no. 1) maka – Wallaahu a’lam – cukup puasa hari ke 9 bersama hari ke 10 (ini yang afdhal) atau ke 10 saja.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Asy-Syaikh Salim Bin Ied Al Hilaly mengatakan bahwa, “Sebagian ahlu ilmu berpendapat bahwa menyelisihi orang Yahudi terjadi dengan puasa sebelumnya atau sesudahnya. Mereka berdalil dengan hadits yang diriwayatkan dari Rasulullah Shalallahu’alaihi Wasallam,</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
صوموا يوم عاشوراء و خالفوا فيه اليهود صوموا قبله يوما أو بعده يوما .</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
“Puasalah kalian hari ‘Asyura dan selisihilah orang-orang Yahudi padanya (maka) puasalah sehari sebelumnya atau sehari setelahnya”.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Ini adalah pendapat yang lemah, karena bersandar dengan hadits yang lemah tersebut yang pada sanadnya terdapat Ibnu Abi Laila dan ia adalah jelek hafalannya.” (Bahjatun Nadhirin Syarah Riyadhus Shalihin II/385. cet. IV. Th. 1423 H Dar Ibnu Jauzi)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
[4] (lihat no. 3)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
[5] Asy-Syaikh Muhammad Bin Shalih Al-Utsaimin rahimahullah mengatakan,</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
والراجح أنه لا يكره إفراد عاشوراء.</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Dan yang rajih adalah bahwa tidak dimakruhkan berpuasa ‘Asyura saja. (Syarhul Mumthi’ VI)</div>
<div style="background-color: white; color: #666666; font-family: Tahoma, Arial; font-size: 12px; line-height: 18px; text-align: -webkit-auto;">
Wallaahu a’lam.</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-1570982086998881522011-12-03T04:24:00.001-08:002011-12-28T17:13:26.607-08:00VB.NET: Connect to SQL Server<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; text-align: justify;">
</div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;"><b>Here is the step-by-step procedure to connect to SQL server:</b><o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">1. Create your VB.NET project.<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">2. Include the following namespaces.<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<o:p><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"><br /></span></o:p></div>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: 'Courier New', Courier, monospace;">Imports System.Data<br />Imports System.Data.SqlClient</span></blockquote>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">The System.Data namespace provides access to classes that
represent the ADO.NET architecture while the System.Data.SqlClient namespace is
the.NET Framework Data Provider for SQL Server.<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">3. Declare and instantiate your SQLConnection object as
shown below<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;"><span class="Apple-style-span" style="color: #cc0000;">Dim con As New SqlConnection</span></span></blockquote>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">SQLConnection class represents an open connection to a SQL
Server database.<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">4. Pass the SQL connection string to ConnectionString
property of your SqlConnection object.<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;"><span class="Apple-style-span" style="color: #cc0000;">con.ConnectionString = "Data Source=atisource;Initial
Catalog=BillingSys;Persist Security Info=True;User
ID=sa;Password=12345678"</span></span></blockquote>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">The connectionstring value usually contains the following :<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Data Source - physical server hostname<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Initial Catalog - your database name<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">User ID - SQL username use to connect to the server<o:p></o:p></span></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Password - SQL username's password<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">On this sample, I am using an SQL Server 2005. For the
connectionstring for other SQL version, you can get it from <a href="http://asnsblues.blogspot.com/2011/12/connection-strings-for-sql-server-2005.html">here </a><o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">5. Last step is to invoke the Open method of the connection
object<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">con.Open()</span><o:p><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></o:p></span></blockquote>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">The complete sample sourcecode:<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Imports System.Data.SqlClient</span></span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Imports System.Data</span><o:p><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></o:p></span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Private Sub ConnectToSQL()</span><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Dim con As New
SqlConnection</span><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">Dim cmd As New
SqlCommand</span><o:p><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></o:p><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">con.ConnectionString
= "Data Source=atisource;Initial Catalog=BillingSys;Persist Security Info=True;User ID=sa;Password=12345678"</span><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"> </span></span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">con.Open()</span><span class="Apple-style-span" style="font-family: Verdana, sans-serif;">End Sub </span></span></blockquote>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span class="Apple-style-span" style="font-family: Verdana, sans-serif;">To capture if the connection was successful or not, just
tweak the above code:<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">Imports System.Data.SqlClient</span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">Imports System.Data</span><o:p><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> </span></o:p> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">Private Sub ConnectToSQL()</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> </span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">Dim con As New
SqlConnection</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> </span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">Dim cmd As New
SqlCommand</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> Try</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> </span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">con.ConnectionString
= "Data Source=atisource;Initial Catalog=BillingSys;Persist Security Info=True;User
ID=sa;Password=12345678"</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> </span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">con.Open()</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> Catch ex As Exception</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">
MessageBox.Show("Error while connecting to SQL Server." &
ex.Message)</span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">Finally</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> </span> </blockquote>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;">con.Close() 'Whether
there is error or not. Close the connection.</span><span class="Apple-style-span" style="color: #cc0000; font-family: Verdana, sans-serif;"> End Try</span><span class="Apple-style-span" style="font-family: Verdana, sans-serif;"><span class="Apple-style-span" style="color: #cc0000;">End Sub</span></span></blockquote>
<table bgcolor="Linen" border="0" id="Table3" title="DataReader with a Console Application"><tbody>
<tr><td style="font-family: Verdana; font-size: x-small; word-spacing: normal;"><span class="Apple-style-span" style="font-family: Verdana, sans-serif; font-size: small;"><br /></span></td></tr>
</tbody></table>
<br /></div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com2tag:blogger.com,1999:blog-4467336557173928576.post-40898939936737212932011-12-03T04:16:00.001-08:002011-12-03T04:37:44.145-08:00Connection strings for SQL Server 2005<div dir="ltr" style="text-align: left;" trbidi="on">
<span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">in</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">my previous</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">article</span><span style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">,</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">I was asked</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">to</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">give</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">a tutorial on</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">sql</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">server and</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">vb.net</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;">connection. in this case i use SQL Server 2005 Standard edition.<br /><br />so this is all connections strings providers for SQL Server 2005<br />Note : I assumed that you already installed SQL Server and Visual studio also use<br />this setting :<br /><br /><span style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;">Server address</span><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><input class="carrierCustomizeTextBox" id="textboxServerAddress" name="textboxServerAddress" style="border-bottom-color: rgb(170, 170, 170); border-bottom-style: dashed; border-bottom-width: 1px; border-left-color: initial; border-left-style: none; border-left-width: initial; border-right-color: initial; border-right-style: none; border-right-width: initial; border-top-color: initial; border-top-style: none; border-top-width: initial; color: navy; font-family: 'Courier New'; font-size: 12px; padding-bottom: 2px; padding-left: 5px; padding-right: 5px; padding-top: 2px; width: 172px;" type="text" value="10.252.108.103" /><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><br style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;" /><span style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;">Database name</span><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><input class="carrierCustomizeTextBox" id="textboxDatabaseName" name="textboxDatabaseName" style="border-bottom-color: rgb(170, 170, 170); border-bottom-style: dashed; border-bottom-width: 1px; border-left-color: initial; border-left-style: none; border-left-width: initial; border-right-color: initial; border-right-style: none; border-right-width: initial; border-top-color: initial; border-top-style: none; border-top-width: initial; color: navy; font-family: 'Courier New'; font-size: 12px; padding-bottom: 2px; padding-left: 5px; padding-right: 5px; padding-top: 2px; width: 170px;" type="text" value="SQLServ2005" /><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><br style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;" /><span style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;">Username</span><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><input class="carrierCustomizeTextBox" id="textboxUsername" name="textboxUsername" style="border-bottom-color: rgb(170, 170, 170); border-bottom-style: dashed; border-bottom-width: 1px; border-left-color: initial; border-left-style: none; border-left-width: initial; border-right-color: initial; border-right-style: none; border-right-width: initial; border-top-color: initial; border-top-style: none; border-top-width: initial; color: navy; font-family: 'Courier New'; font-size: 12px; padding-bottom: 2px; padding-left: 5px; padding-right: 5px; padding-top: 2px; width: 200px;" type="text" value="adelva" /><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><br style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;" /><span style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;">Password</span><span class="Apple-style-span" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 11px;"> </span><input class="carrierCustomizeTextBox" id="textboxPassword" name="textboxPassword" style="border-bottom-color: rgb(170, 170, 170); border-bottom-style: dashed; border-bottom-width: 1px; border-left-color: initial; border-left-style: none; border-left-width: initial; border-right-color: initial; border-right-style: none; border-right-width: initial; border-top-color: initial; border-top-style: none; border-top-width: initial; color: navy; font-family: 'Courier New'; font-size: 12px; padding-bottom: 2px; padding-left: 5px; padding-right: 5px; padding-top: 2px; width: 205px;" type="text" value="p@ssw0rd" /></span><br />
<span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"><br />"adevla" was my localhost username XD</span><br />
<span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; font-size: 16px; text-align: -webkit-auto;"></span><br />
<h2 style="background-color: white; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
.NET Framework Data Provider for SQL Server</h2>
<div class="cs_pi" style="background-color: white; color: black; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">.NET Framework Class Library</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">System.Data.SqlClient.SqlConnection</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<div style="font-size: 11px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span></div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Standard Security</span></h3>
<span class="cs_pi_value" style="color: #444444;">
<div class="cs_csbox" id="p0cs1" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; text-align: -webkit-auto; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Data Source=10.252.108.103;Initial Catalog=SQLServ2005;User Id=adelva;Password=p@ssw0rd;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; text-align: -webkit-auto; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Use serverName\instanceName as Data Source to connect to a specific SQL Server instance.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Are you using SQL Server 2005 Express? Don't miss the server name syntax Servername\SQLEXPRESS where you substitute Servername with the name of the computer where the SQL Server 2005 Express installation resides.</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px; text-align: -webkit-auto;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal; text-align: -webkit-auto;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto;">
Standard Security alternative syntax</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; text-align: -webkit-auto; width: 700px;">
This connection string produce the same result as the previous one. The reason to include it is to point out that some connection string keywords have many equivalents.</div>
<div class="cs_csbox" id="p0cs2" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; text-align: -webkit-auto; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=10.252.108.103;Database=SQLServ2005;User ID=adelva;Password=p@ssw0rd;Trusted_Connection=False;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; text-align: -webkit-auto; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px; text-align: -webkit-auto;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal; text-align: -webkit-auto;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto;">
Trusted Connection</h3>
<div class="cs_csbox" id="p0cs3" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; text-align: -webkit-auto; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Data Source=10.252.108.103;Initial Catalog=SQLServ2005;Integrated Security=SSPI;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; text-align: -webkit-auto; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px; text-align: -webkit-auto;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal; text-align: -webkit-auto;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto;">
Trusted Connection alternative syntax</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; text-align: -webkit-auto; width: 700px;">
This connection string produce the same result as the previous one. The reason to include it is to point out that some connection string keywords have many equivalents.</div>
<div class="cs_csbox" id="p0cs4" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; text-align: -webkit-auto; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=10.252.108.103;Database=SQLServ2005;Trusted_Connection=True;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; text-align: -webkit-auto; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px; text-align: -webkit-auto;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal; text-align: -webkit-auto;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto;">
Connecting to an SQL Server instance</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; text-align: -webkit-auto; width: 700px;">
The syntax of specifying the server instance in the value of the server key is the same for all connection strings for SQL Server.</div>
<div class="cs_csbox" id="p0cs5" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; text-align: -webkit-auto; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=myServerName\theInstanceName;Database=SQLServ2005;Trusted_Connection=True;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; text-align: -webkit-auto; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px; text-align: -webkit-auto;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal; text-align: -webkit-auto;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto;">
Trusted Connection from a CE device</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; text-align: -webkit-auto; width: 700px;">
Often a Windows CE device is not authenticated and logged in to a domain. To use SSPI or trusted connection / authentication from a CE device, use this connection string.</div>
<div class="cs_csbox" id="p0cs6" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; text-align: -webkit-auto; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Data Source=10.252.108.103;Initial Catalog=SQLServ2005;Integrated Security=SSPI;User ID=myDomain\myUsername;Password=myPassword;</span></div>
<div class="cs_bi" style="color: black; float: left; line-height: normal; text-align: -webkit-auto; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Note that this will only work on a CE device.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Connect via an IP address</h3>
<div class="cs_csbox" id="p0cs7" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Data Source=190.190.200.100,1433;Network Library=DBMSSOCN;Initial Catalog=SQLServ2005;User ID=adelva;Password=p@ssw0rd;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
DBMSSOCN=TCP/IP. This is how to use TCP/IP instead of Named Pipes. At the end of the Data Source is the port to use. 1433 is the default port for SQL Server.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.connectionstrings.com/Articles/Show/define-sql-server-network-protocol" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">How to define which network protocol to use</a></div>
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Enabling MARS (multiple active result sets)</h3>
<div class="cs_csbox" id="p0cs8" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=10.252.108.103;Database=SQLServ2005;Trusted_Connection=True; MultipleActiveResultSets=true;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Use ADO.NET 2.0 for MARS functionality. MARS is not supported in ADO.NET 1.0 nor ADO.NET 1.1.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.devx.com/dbzone/Article/30132" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Streamline your Data Connections by Moving to MARS, by Laurence Moroney, DevX.com</a></div>
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p0cs9" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=.\SQLExpress;AttachDbFilename=c:\mydbfile.mdf;Database=dbname; Trusted_Connection=Yes;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file, located in the data directory, on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p0cs10" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=.\SQLExpress;AttachDbFilename=|DataDirectory|mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Using an User Instance on a local SQL Server Express instance</h3>
<div style="font-size: 11px; margin-left: 4px; margin-top: 5px; width: 700px;">
The User Instance functionality creates a new SQL Server instance on the fly during connect. This works only on a local SQL Server 2005 instance and only when connecting using windows authentication over local named pipes. The purpose is to be able to create a full rights SQL Server instance to a user with limited administrative rights on the computer.</div>
<div class="cs_csbox" id="p0cs11" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Data Source=.\SQLExpress;Integrated Security=true; AttachDbFilename=|DataDirectory|\mydb.mdf;User Instance=true;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
To use the User Instance functionality you need to enable it on the SQL Server. This is done by executing the following command: sp_configure 'user instances enabled', '1'. To disable the functionality execute sp_configure 'user instances enabled', '0'.</div>
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Database mirroring</h3>
<div style="font-size: 11px; margin-left: 4px; margin-top: 5px; width: 700px;">
If you connect with ADO.NET or the SQL Native Client to a database that is being mirrored, your application can take advantage of the drivers ability to automatically redirect connections when a database mirroring failover occurs. You must specify the initial principal server and database in the connection string and the failover partner server.</div>
<div class="cs_csbox" id="p0cs12" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Data Source=10.252.108.103;Failover Partner=myMirrorServerAddress;Initial Catalog=SQLServ2005;Integrated Security=True;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
There is ofcourse many other ways to write the connection string using database mirroring, this is just one example pointing out the failover functionality. You can combine this with the other connection strings options available.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.microsoft.com/technet/prodtechnol/sql/2005/dbmirror.mspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Read more about database mirroring in this Microsoft TechNet article "Database Mirroring in SQL Server 2005"</a></div>
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Asynchronous processing</h3>
<div style="font-size: 11px; margin-left: 4px; margin-top: 5px; width: 700px;">
A connection to SQL Server 2005 that allows for the issuing of async requests through ADO.NET objects.</div>
<div class="cs_csbox" id="p0cs13" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Server=10.252.108.103;Database=SQLServ2005;Integrated Security=True;Asynchronous Processing=True;</span></div>
<div class="cs_bi" style="float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h2 style="font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
SQL Native Client 9.0 OLE DB provider</h2>
<div class="cs_pi" style="line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">OLE DB Provider</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Provider=SQLNCLI</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<div style="font-size: 11px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span></div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Standard security</span></h3>
<span class="cs_pi_value" style="color: #444444;">
<div class="cs_csbox" id="p1cs1" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=10.252.108.103;Database=SQLServ2005;Uid=adelva; <br />Pwd=p@ssw0rd;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Are you using SQL Server 2005 Express? Don't miss the server name syntax Servername\SQLEXPRESS where you substitute Servername with the name of the computer where the SQL Server 2005 Express installation resides.</div>
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Trusted connection</h3>
<div class="cs_csbox" id="p1cs2" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=10.252.108.103;Database=SQLServ2005;<br />Trusted_Connection=yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Equivalent key-value pair: "Integrated Security=SSPI" equals "Trusted_Connection=yes"</div>
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Connecting to an SQL Server instance</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
The syntax of specifying the server instance in the value of the server key is the same for all connection strings for SQL Server.</div>
<div class="cs_csbox" id="p1cs3" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=myServerName\theInstanceName;Database=SQLServ2005; Trusted_Connection=yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Prompt for username and password</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
This one is a bit tricky. First you need to set the connection object's Prompt property to adPromptAlways. Then use the connection string to connect to the database.</div>
<div class="cs_csbox" id="p1cs4" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">oConn.Properties("Prompt") = adPromptAlways</span><br />
<span class="Apple-style-span" style="font-size: x-small;"><br /></span><br />
<span class="Apple-style-span" style="font-size: x-small;">oConn.Open "Provider=SQLNCLI;<br />Server=10.252.108.103;DataBase=SQLServ2005;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Enabling MARS (multiple active result sets)</h3>
<div class="cs_csbox" id="p1cs5" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;MARS Connection=True;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Use ADO.NET 2.0 for MARS functionality. MARS is not supported in ADO.NET 1.0 nor ADO.NET 1.1.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://blogs.msdn.com/b/dataaccess/archive/2005/08/02/446894.aspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Using MARS with SQL Native Client, by Chris Lee</a></div>
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Encrypt data sent over network</h3>
<div class="cs_csbox" id="p1cs6" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;Encrypt=yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p1cs7" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=.\SQLExpress;AttachDbFilename=c:\mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file, located in the data directory, on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p1cs8" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=.\SQLExpress;<br />AttachDbFilename=|DataDirectory|mydbfile.mdf; <br />Database=dbname;Trusted_Connection=Yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://download.microsoft.com/download/4/4/D/44DBDE61-B385-4FC2-A67D-48053B8F9FAD/sqlncli.msi" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Download the SQL Native Client here. The package contains booth the ODBC driver and the OLE DB provider</a></div>
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Database mirroring</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
If you connect with ADO.NET or the SQL Native Client to a database that is being mirrored, your application can take advantage of the drivers ability to automatically redirect connections when a database mirroring failover occurs. You must specify the initial principal server and database in the connection string and the failover partner server.</div>
<div class="cs_csbox" id="p1cs9" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Data Source=10.252.108.103;Failover Partner=myMirrorServerAddress;Initial Catalog=SQLServ2005;<br />Integrated Security=True;</span></div>
<div class="cs_bi" style="color: black; float: left; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
There is ofcourse many other ways to write the connection string using database mirroring, this is just one example pointing out the failover functionality. You can combine this with the other connection strings options available.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.microsoft.com/technet/prodtechnol/sql/2005/dbmirror.mspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Read more about database mirroring in this Microsoft TechNet article "Database Mirroring in SQL Server 2005"</a></div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<br /></div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
</div>
<h2 style="font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
.NET Framework Data Provider for OLE DB</h2>
<div class="cs_pi" style="line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">.NET Framework Wrapper Class Library</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">System.Data.OleDb.OleDbConnection</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<div style="font-size: 11px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span></div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Bridging to SQL Native Client OLE DB</span></h3>
<span class="cs_pi_value" style="color: #444444;">
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
This is just one connection string sample for the wrapping OleDbConnection class that calls the underlying OLEDB provider. See respective OLE DB provider for more connection strings to use with this class.</div>
<div class="cs_csbox" id="p2cs1" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI;Server=10.252.108.103;Database=SQLServ2005;<br />Uid=adelva; Pwd=p@ssw0rd;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
</span><div style="font-size: 11px;">
</div>
<h2 style="font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
SQL Server Native Client 10.0 OLE DB Provider</h2>
<div class="cs_pi" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">OLE DB Provider</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Provider=SQLNCLI10</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<div style="font-size: 11px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span></div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Standard security</span></h3>
<span class="cs_pi_value" style="color: #444444;">
<div class="cs_csbox" id="p3cs1" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=10.252.108.103;Database=SQLServ2005;<br />Uid=adelva; Pwd=p@ssw0rd;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Are you using SQL Server 2005 Express? Don't miss the server name syntax Servername\SQLEXPRESS where you substitute Servername with the name of the computer where the SQL Server 2005 Express installation resides.</div>
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Trusted connection</h3>
<div class="cs_csbox" id="p3cs2" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=10.252.108.103;Database=SQLServ2005;<br />Trusted_Connection=yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Equivalent key-value pair: "Integrated Security=SSPI" equals "Trusted_Connection=yes"</div>
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Connecting to an SQL Server instance</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
The syntax of specifying the server instance in the value of the server key is the same for all connection strings for SQL Server.</div>
<div class="cs_csbox" id="p3cs3" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=myServerName\theInstanceName;Database=SQLServ2005; Trusted_Connection=yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Prompt for username and password</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
This one is a bit tricky. First you need to set the connection object's Prompt property to adPromptAlways. Then use the connection string to connect to the database.</div>
<div class="cs_csbox" id="p3cs4" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">oConn.Properties("Prompt") = adPromptAlways</span><br />
<span class="Apple-style-span" style="font-size: x-small;"><br /></span><br />
<span class="Apple-style-span" style="font-size: x-small;">oConn.Open "Provider=SQLNCLI10;Server=10.252.108.103;<br />DataBase=SQLServ2005;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Enabling MARS (multiple active result sets)</h3>
<div class="cs_csbox" id="p3cs5" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;MARS Connection=True;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Use ADO.NET 2.0 for MARS functionality. MARS is not supported in ADO.NET 1.0 nor ADO.NET 1.1.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://blogs.msdn.com/b/dataaccess/archive/2005/08/02/446894.aspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Using MARS with SQL Native Client, by Chris Lee</a></div>
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Encrypt data sent over network</h3>
<div class="cs_csbox" id="p3cs6" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;Encrypt=yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<br />
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p3cs7" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=.\SQLExpress;AttachDbFilename=c:\mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</span></div>
<div class="cs_bi" style="color: black; float: left; line-height: normal; width: 640px;">
<div style="line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
<div style="font-size: 11px;">
<br /></div>
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file, located in the data directory, on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p3cs8" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Server=.\SQLExpress;<br />AttachDbFilename=|DataDirectory|mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://download.microsoft.com/download/4/4/D/44DBDE61-B385-4FC2-A67D-48053B8F9FAD/sqlncli.msi" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Download the SQL Native Client here. The package contains booth the ODBC driver and the OLE DB provider</a></div>
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Database mirroring</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
If you connect with ADO.NET or the SQL Native Client to a database that is being mirrored, your application can take advantage of the drivers ability to automatically redirect connections when a database mirroring failover occurs. You must specify the initial principal server and database in the connection string and the failover partner server.</div>
<div class="cs_csbox" id="p3cs9" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="Apple-style-span" style="font-size: x-small;">Provider=SQLNCLI10;Data Source=10.252.108.103;Failover Partner=myMirrorServerAddress;Initial Catalog=SQLServ2005;<br />Integrated Security=True;</span></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
There is ofcourse many other ways to write the connection string using database mirroring, this is just one example pointing out the failover functionality. You can combine this with the other connection strings options available.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.microsoft.com/technet/prodtechnol/sql/2005/dbmirror.mspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Read more about database mirroring in this Microsoft TechNet article "Database Mirroring in SQL Server 2005"</a></div>
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
<h2 style="font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
SQL Native Client 9.0 ODBC Driver</h2>
<div class="cs_pi" style="line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">ODBC Driver</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Driver={SQL Native Client}</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span><br />
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Standard security</span></h3>
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
<div class="cs_csbox" id="p4cs1" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=10.252.108.103;Database=SQLServ2005; Uid=adelva;Pwd=p@ssw0rd;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Are you using SQL Server 2005 Express? Don't miss the server name syntax Servername\SQLEXPRESS where you substitute Servername with the name of the computer where the SQL Server 2005 Express installation resides.</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Trusted Connection</h3>
<div class="cs_csbox" id="p4cs2" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Equivalent key-value pair: "Integrated Security=SSPI" equals "Trusted_Connection=yes"</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Connecting to an SQL Server instance</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
The syntax of specifying the server instance in the value of the server key is the same for all connection strings for SQL Server.</div>
<div class="cs_csbox" id="p4cs3" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=myServerName\theInstanceName;Database=SQLServ2005; Trusted_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Prompt for username and password</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
This one is a bit tricky. First you need to set the connection object's Prompt property to adPromptAlways. Then use the connection string to connect to the database.</div>
<div class="cs_csbox" id="p4cs4" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
oConn.Properties("Prompt") = adPromptAlways<br />
<br />
Driver={SQL Native Client};Server=10.252.108.103;Database=SQLServ2005;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Enabling MARS (multiple active result sets)</h3>
<div class="cs_csbox" id="p4cs5" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;MARS_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Use ADO.NET 2.0 for MARS functionality. MARS is not supported in ADO.NET 1.0 nor ADO.NET 1.1.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://blogs.msdn.com/b/dataaccess/archive/2005/08/02/446894.aspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Using MARS with SQL Native Client, by Chris Lee</a></div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Encrypt data sent over network</h3>
<div class="cs_csbox" id="p4cs6" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;Encrypt=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p4cs7" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=.\SQLExpress;AttachDbFilename=c:\mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file, located in the data directory, on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p4cs8" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Native Client};Server=.\SQLExpress; AttachDbFilename=|DataDirectory|mydbfile.mdf;Database=dbname;Trusted_Connection=Yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://download.microsoft.com/download/4/4/D/44DBDE61-B385-4FC2-A67D-48053B8F9FAD/sqlncli.msi" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Download the SQL Native Client here. The package contains booth the ODBC driver and the OLE DB provider</a></div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Database mirroring</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
If you connect with ADO.NET or the SQL Native Client to a database that is being mirrored, your application can take advantage of the drivers ability to automatically redirect connections when a database mirroring failover occurs. You must specify the initial principal server and database in the connection string and the failover partner server.</div>
<div class="cs_csbox" id="p4cs9" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Failover_Partner=myMirrorServerAddress;Database=SQLServ2005; Trusted_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
There is ofcourse many other ways to write the connection string using database mirroring, this is just one example pointing out the failover functionality. You can combine this with the other connection strings options available.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Please note if you are using TCP/IP (using the network library parameter) and database mirroring, including port number in the address (formed as servername,portnumber) for booth the main server and the failover partner can solve some reported issues.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.microsoft.com/technet/prodtechnol/sql/2005/dbmirror.mspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Read more about database mirroring in this Microsoft TechNet article "Database Mirroring in SQL Server 2005"</a></div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
</span><br />
<h2 style="font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
SQL Server Native Client 10.0 ODBC Driver</h2>
<div class="cs_pi" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">ODBC Driver</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Driver={SQL Server Native Client 10.0}</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span><br />
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Standard security</span></h3>
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
<div class="cs_csbox" id="p5cs1" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Database=SQLServ2005;Uid=adelva;Pwd=p@ssw0rd;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Trusted Connection</h3>
<div class="cs_csbox" id="p5cs2" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Database=SQLServ2005;Trusted_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Equivalent key-value pair: "Integrated Security=SSPI" equals "Trusted_Connection=yes"</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Connecting to an SQL Server instance</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
The syntax of specifying the server instance in the value of the server key is the same for all connection strings for SQL Server.</div>
<div class="cs_csbox" id="p5cs3" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=myServerName\theInstanceName; Database=SQLServ2005;Trusted_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Prompt for username and password</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
This one is a bit tricky. First you need to set the connection object's Prompt property to adPromptAlways. Then use the connection string to connect to the database.</div>
<div class="cs_csbox" id="p5cs4" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
oConn.Properties("Prompt") = adPromptAlways<br />
<br />
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Database=SQLServ2005;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Enabling MARS (multiple active result sets)</h3>
<div class="cs_csbox" id="p5cs5" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Database=SQLServ2005;Trusted_Connection=yes; MARS_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Use ADO.NET for MARS functionality. MARS is not supported in ADO.NET 1.0 nor ADO.NET 1.1.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://blogs.msdn.com/b/dataaccess/archive/2005/08/02/446894.aspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Using MARS with SQL Native Client, by Chris Lee</a></div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Encrypt data sent over network</h3>
<div class="cs_csbox" id="p5cs6" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Database=SQLServ2005; Trusted_Connection=yes;Encrypt=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p5cs7" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=.\SQLExpress; AttachDbFilename=c:\asd\qwe\mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Attach a database file, located in the data directory, on connect to a local SQL Server Express instance</h3>
<div class="cs_csbox" id="p5cs8" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=.\SQLExpress;AttachDbFilename=|DataDirectory|mydbfile.mdf; Database=dbname;Trusted_Connection=Yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Why is the Database parameter needed? If the named database have already been attached, SQL Server does not reattach it. It uses the attached database as the default for the connection.</div>
</div>
<div class="cs_ctc" style="color: black; float: left; font-size: 11px; line-height: normal; margin-left: 40px; margin-top: 0px;">
<a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></div>
<div class="cs_after" style="clear: both; color: black; font-size: 11px; height: 20px; line-height: normal;">
</div>
<h3 style="clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Database mirroring</h3>
<div style="color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
If you connect with ADO.NET or the SQL Native Client to a database that is being mirrored, your application can take advantage of the drivers ability to automatically redirect connections when a database mirroring failover occurs. You must specify the initial principal server and database in the connection string and the failover partner server.</div>
<div class="cs_csbox" id="p5cs9" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Failover_Partner=myMirrorServerAddress;Database=SQLServ2005; Trusted_Connection=yes;</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
There is ofcourse many other ways to write the connection string using database mirroring, this is just one example pointing out the failover functionality. You can combine this with the other connection strings options available.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
Please note if you are using TCP/IP (using the network library parameter) and database mirroring, including port number in the address (formed as servername,portnumber) for booth the main server and the failover partner can solve some reported issues.</div>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 8px; width: 640px;">
<a href="http://www.microsoft.com/technet/prodtechnol/sql/2005/dbmirror.mspx" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;">Read more about database mirroring in this Microsoft TechNet article "Database Mirroring in SQL Server 2005"</a></div>
</div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<br /></div>
<div class="cs_bi" style="color: black; float: left; font-size: 11px; line-height: normal; width: 640px;">
<h2 style="font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
.NET Framework Data Provider for ODBC</h2>
<div class="cs_pi" style="line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">.NET Framework Wrapper Class Library</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">System.Data.Odbc.OdbcConnection</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span><br />
<div class="cs_c" style="color: black; font-size: 11px; line-height: normal;">
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Bridging to SQL Native Client 10.0 ODBC Driver</span></h3>
<div style="font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">This is just one connection string sample for the wrapping OdbcConnection class that calls the underlying ODBC Driver. See respective ODBC driver for more connection strings to use with this class.</span></div>
<div class="cs_csbox" id="p6cs1" style="background-color: #e0e0e0; border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Driver={SQL Server Native Client 10.0};Server=10.252.108.103;Database=SQLServ2005;Uid=adelva;Pwd=p@ssw0rd;</span></div>
<div class="cs_bi" style="float: left; width: 640px;">
</div>
<div class="cs_ctc" style="float: left; margin-left: 40px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><a href="http://www.connectionstrings.com/sql-server-2005" style="color: #3333dd; display: block; font-size: 0.7em; line-height: 20px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none; text-transform: uppercase;">COPY</a></span></div>
<div class="cs_after" style="clear: both; height: 20px;">
</div>
</div>
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
<a href="http://www.blogger.com/blogger.g?blogID=4467336557173928576" id="p4" style="color: #3333dd; font-size: 11px; line-height: normal; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;"></a><div class="cs_p" style="border-bottom-color: rgb(230, 230, 187); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(230, 230, 187); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(230, 230, 187); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(230, 230, 187); border-top-style: solid; border-top-width: 1px; clear: left; color: black; font-size: 11px; line-height: normal; margin-bottom: 20px; margin-left: 0px; margin-right: 0px; margin-top: 40px;">
<h2 style="background-color: #ffffdd; font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
SQLXML 4.0 OLEDB Provider</h2>
<div class="cs_pi" style="background-color: #ffffee; line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">OLE DB Provider</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Provider=SQLXMLOLEDB.4.0;Data Provider=providername</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
</div>
</div>
</span></div>
</div>
</div>
</span></div>
</div>
</div>
</div>
</div>
</span><div style="font-size: 11px;">
</div>
</div>
</div>
</div>
</div>
<div style="font-size: 11px;">
<br /></div>
<div style="font-size: 11px;">
<br /></div>
</div>
<div class="cs_bi" style="color: black; float: left; line-height: normal; width: 640px;">
<div class="cs_c" style="font-size: 11px;">
<h3 style="clear: left; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
Using SQL Server Native Client provider</h3>
<div class="cs_csbox" id="p7cs1" style="background-color: #e0e0e0; border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; font-size: 1.2em; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
Provider=SQLXMLOLEDB.4.0;Data Provider=SQLNCLI;<br />Data Source=10.252.108.103;Initial Catalog=SQLServ2005;User Id=adelva;Password=p@ssw0rd;</div>
<div class="cs_bi" style="float: left; width: 640px;">
</div>
</div>
<div style="font-size: 11px;">
<a href="http://www.blogger.com/blogger.g?blogID=4467336557173928576" id="p5" style="color: #3333dd; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;"></a></div>
<div class="cs_p" style="border-bottom-color: rgb(230, 230, 187); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(230, 230, 187); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(230, 230, 187); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(230, 230, 187); border-top-style: solid; border-top-width: 1px; clear: left; margin-bottom: 20px; margin-left: 0px; margin-right: 0px; margin-top: 40px;">
<h2 style="background-color: #ffffdd; font-family: Tahoma, Geneva, sans-serif; font-size: 1.9em; font-weight: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 5px; padding-left: 4px; padding-right: 2px; padding-top: 5px; width: 700px;">
Context Connection</h2>
<div class="cs_pi" style="background-color: #ffffee; line-height: 16px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 4px; padding-left: 6px; padding-right: 0px; padding-top: 2px; width: 700px;">
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">TYPE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">.NET Framework Class Library</span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">USAGE</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span><span class="cs_pi_label" style="color: #888888; font-size: 0.7em; margin-bottom: 0px; margin-left: 4px; margin-right: 8px; margin-top: 0px; text-transform: uppercase; vertical-align: top;">MANUFACTURER</span> <span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">Microsoft</span></div>
<div class="cs_pilc" style="float: left; font-size: 11px; width: 460px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"><br /></span></div>
<div class="cs_pilc" style="float: left; width: 460px;">
<div style="font-size: 11px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;"></span></div>
<h3 style="background-color: white; clear: left; color: black; font-family: Tahoma, Geneva, sans-serif; font-size: 1.7em; font-weight: normal; line-height: normal; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px;">
<span class="cs_pi_value" style="color: #444444; font-size: 1.2em;">
Context Connection</span></h3>
<span class="cs_pi_value" style="color: #444444;">
<div style="background-color: white; color: black; font-size: 10px; line-height: 14px; margin-left: 4px; margin-top: 5px; width: 700px;">
Connecting to "self" from within your CLR stored prodedure/function. The context connection lets you execute Transact-SQL statements in the same context (connection) that your code was invoked in the first place.</div>
<div class="cs_csbox" id="p8cs1" style="background-color: white; border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; color: #2222aa; font-family: 'Lucida Console', Monaco, monospace; line-height: 1.3em; margin-bottom: 3px; margin-left: 3px; margin-right: 0px; margin-top: 8px; padding-bottom: 2px; padding-left: 6px; padding-right: 3px; padding-top: 3px; width: 700px;">
<b><span class="Apple-style-span" style="font-size: x-small;">C#</span></b><br />
<span class="Apple-style-span" style="font-size: x-small;"> using(SqlConnection connection = new SqlConnection("context connection=true"))</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> {</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> connection.Open();</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> // Use the connection</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> }</span><br />
<span class="Apple-style-span" style="font-size: x-small;"><br /></span><br />
<b><span class="Apple-style-span" style="font-size: x-small;">VB.Net</span></b><br />
<span class="Apple-style-span" style="font-size: x-small;"> Using connection as new SqlConnection("context connection=true")</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> connection.Open()</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> ' Use the connection</span><br />
<span class="Apple-style-span" style="font-size: x-small;"> End Using</span></div>
</span><div style="font-size: 11px;">
</div>
</div>
</div>
</div>
</div>
</span><div style="font-size: 11px;">
</div>
</div>
</div>
</div>
</span><div style="font-size: 11px;">
</div>
</div>
</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-80750160508999806172011-12-03T03:57:00.001-08:002011-12-03T03:57:04.749-08:00SQL SERVER – FIX – ERROR – Service Logon Failure (ObjectExplorer)<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Just another day I received following error while starting my agent. As soon as I received following error I felt like Deja Vu. I had similar feeling few days ago. I quickly looked at my blog post history and I found out following article <strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><a href="http://blog.sqlauthority.com/2011/03/29/sql-server-fix-error-the-request-failed-or-the-service-did-not-respond-in-timely-fashion-consult-the-event-log-or-other-applicable-error-logs-for-details/" style="border-bottom-color: rgb(56, 79, 131); border-bottom-style: dashed; border-bottom-width: 1px; color: #384f83; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;" target="_blank">SQL SERVER – Fix : Error : The request failed or the service did not respond in timely fashion. Consult the event log or other applicable error logs for details</a></strong>.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<img alt="" class="alignnone" height="123" src="http://www.pinaldave.com/bimg/servicelogonfail.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" width="500" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">TITLE: Microsoft SQL Server Management Studio</span><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">——————————</span><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Unable to start service SQLSERVERAGENT on server PINALKUMAR. (mscorlib)</span><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">——————————</span><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">ADDITIONAL INFORMATION:</span><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Service Logon Failure (ObjectExplorer)</span></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Indeed this was again issue with my changed password which I forget to change it for my SQL Server Agent. Once I changed the password, it fixed itself.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
I guess this should be last time when I change my password and do not change it in my services depending on the same login.</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-50377194760765854652011-12-03T03:53:00.001-08:002011-12-03T03:53:14.372-08:00SQL SERVER – FIX – ERROR : Msg 3201, Level 16 Cannot open backup device . Operating system error 5(Access is denied.)<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Recently I formatted my computer and installed fresh SQL Server in it. I installed AdventureWorks database in my database. Once done I wanted to run few test scripts on my database. Just like every DBA, I decided to take backup of my database – this way I can restore it back to attain original database state. As soon as I ran the backup command I ended up with following error. This error is due to permissions issue on the local disk and user account which is running SQL Server.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Msg 3201, Level 16, State 1, Line 1</span><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Cannot open backup device ‘C:\AdventureWorks.bak’. Operating system error 5(Access is denied.).</span></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Fix/Resolution/Workaround:</strong></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
I checked which user account my SQL Server services are running.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<img alt="" class="alignnone" height="448" src="http://www.pinaldave.com/bimg/NetworkError1.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" width="405" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
I gave full permission to that account to get read of the error.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<img alt="" class="alignnone" height="456" src="http://www.pinaldave.com/bimg/NetworkError2.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" width="377" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
NOTE: This whole experience was done on the my personal machine and not on production server. Please check with your network administrator for permission on production server.</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com3tag:blogger.com,1999:blog-4467336557173928576.post-35272030993135762112011-12-03T03:47:00.001-08:002011-12-03T03:47:50.897-08:00SQL SERVER – Making Database to Read Only – Changing Database to Read/Write<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
“Today i was trying to attach the (MDF,NDF,LDF ) sql server 2008 database which i have received from my client. After attachment the database status is showing (Read-Only) (Eg.database name (Read-Only). How do i make to normal mode for the data updation. is there any query available to resolve this problem. Your help will be highly helpful.”</div>
<h2 style="background-color: white; color: #333333; font-family: Georgia, Verdana, Arial, serif; font-size: 1.4em; font-weight: normal; letter-spacing: 1px; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 1em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Make Database Read Only</h2>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<code style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">USE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">[master]<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />GO</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">ALTER DATABASE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">[TESTDB] </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">SET </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">READ_ONLY </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">WITH </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">NO_WAIT<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />GO</span></code></div>
<h2 style="background-color: white; color: #333333; font-family: Georgia, Verdana, Arial, serif; font-size: 1.4em; font-weight: normal; letter-spacing: 1px; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 1em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Make Database Read/Write</h2>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<code style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">USE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">[master]<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />GO</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">ALTER DATABASE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">[TESTDB] </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">SET </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">READ_WRITE </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">WITH </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">NO_WAIT<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />GO</span></code></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
If you face error that if database is already in use, you can resolve the same by making database in single user mode – here is the guideline <a href="http://blog.sqlauthority.com/2010/02/11/sql-server-alter-database-dbname-set-single_user-with-rollback-immediate/" style="border-bottom-color: rgb(56, 79, 131); border-bottom-style: dashed; border-bottom-width: 1px; color: #384f83; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;" target="_blank">SQL SERVER – ALTER DATABASE dbname SET SINGLE_USER WITH ROLLBACK IMMEDIATE</a>.</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com6tag:blogger.com,1999:blog-4467336557173928576.post-76433012880441415722011-12-03T03:46:00.001-08:002011-12-03T03:46:23.411-08:00SQL SERVER – Copy Database from Instance to Another Instance – Copy Paste in SQL Server<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
SQL Server has feature which copy database from one database to another database and it can be automated as well using SSIS.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Make sure you have SQL Server Agent Turned on as this feature will create a job. The same job will execute the task. Make sure that SSIS is properly configured as well with necessary security permissions. You can automate this process as well control error logging.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Following are the steps to copy database from one instance to another instance.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<img alt="" class="alignnone" height="546" src="http://www.pinaldave.com/bimg/copywizard1.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" width="496" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard2.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />Specify Source Server<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard3.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />Specify Destination Server<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard4.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />Here you can select option if you want to keep the database ONLINE when it is being copied.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard5.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />You can also select option of MOVE or COPY database as well.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">
<img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard6.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />Give appropriate database name.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard7.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />On this screen you can select additional options to copy as well.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard8.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />You create the package over here.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard9.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />You can schedule the package using SQL Server Agent.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard10.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">
<img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard11.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">
<img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard12.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />When this process is over it will show the success message and database will be copied to another server.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><img alt="" class="alignnone" src="http://www.pinaldave.com/bimg/copywizard13.jpg" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://s0.wp.com/wp-content/themes/pub/mistylook/img/shadow.gif); background-origin: initial; background-position: 100% 100%; background-repeat: no-repeat no-repeat; border-bottom-style: none; border-color: initial; border-left-color: rgb(238, 238, 238); border-left-style: solid; border-left-width: 1px; border-right-style: none; border-top-color: rgb(238, 238, 238); border-top-style: solid; border-top-width: 1px; border-width: initial; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 4px; padding-right: 10px; padding-top: 4px;" /></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
You can see how easy is the process to copy the database to another server.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Reference:<strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"> Pinal Dave (</strong><a href="http://blog.sqlauthority.com/" style="border-bottom-color: rgb(56, 79, 131); border-bottom-style: dashed; border-bottom-width: 1px; color: #384f83; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;" target="_blank"><strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">http://blog.SQLAuthority.com</strong></a><strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">)</strong></div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com1tag:blogger.com,1999:blog-4467336557173928576.post-190361470733083882011-12-03T03:42:00.001-08:002011-12-03T03:42:49.494-08:00SQL SERVER – Restore Database Backup using SQL Script (T-SQL)<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
Database YourDB has full backup YourBaackUpFile.bak. It can be restored using following two steps.</div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Step 1:</strong> Retrive the Logical file name of the database from backup.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><code style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">RESTORE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">FILELISTONLY</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">FROM DISK = </span><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">'D:BackUpYourBaackUpFile.bak'</span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">GO</span></code><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Step 2:</strong> Use the values in the LogicalName Column in following Step.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /><code style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span style="color: green; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">----Make Database to single user Mode</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">ALTER DATABASE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">YourDB</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">SET </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">SINGLE_USER </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">WITH<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />ROLLBACK </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">IMMEDIATE</span></code></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<code style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span style="color: green; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">----Restore Database</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">RESTORE DATABASE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">YourDB</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">FROM DISK = </span><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">'D:BackUpYourBaackUpFile.bak'</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">WITH </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">MOVE </span><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">'YourMDFLogicalName' </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">TO </span><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">'D:DataYourMDFFile.mdf'</span><span style="color: grey; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">,</span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">MOVE </span><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">'YourLDFLogicalName' </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">TO </span><span style="color: red; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">'D:DataYourLDFFile.ldf'</span></code></div>
<div style="background-color: white; color: #333333; font-family: verdana, tahoma, arial, sans-serif; font-size: 12px; line-height: 19px; margin-bottom: 0.7em; margin-top: 0.7em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: justify;">
<code style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span style="color: green; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">/*If there is no error in statement before database will be in multiuser<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />mode.<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />If error occurs please execute following command it will convert<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />database in multi user.*/</span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">ALTER DATABASE </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">YourDB </span><span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">SET </span><span style="color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">MULTI_USER<br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />GO</span></code><br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />Reference : <strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">Pinal Dave (</strong><a href="http://blog.sqlauthority.com/" style="border-bottom-color: rgb(56, 79, 131); border-bottom-style: dashed; border-bottom-width: 1px; color: #384f83; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;" target="_blank"><strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">http://blog.SQLAuthority.com</strong></a><strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">)</strong></div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-59318499523231597082011-12-02T04:46:00.001-08:002011-12-02T04:46:14.284-08:00Query String : provides utilities for dealing with query strings on Node.js<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<h3 id="querystring.stringify" style="font-family: Georgia, FreeSerif, Times, serif; font-size: 1.5em; line-height: 1.0909em; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 1.5em; position: relative; text-rendering: optimizelegibility;">
querystring.stringify(obj, sep='&', eq='=')<a href="http://nodejs.org/docs/latest/api/querystring.html#querystring.stringify" style="color: black; float: right; font-size: 0.8em; opacity: 0.3; text-decoration: none;">#</a></h3>
<div style="color: #222222; font-family: Georgia, FreeSerif, Times, serif; font-size: 15px; line-height: 22px; margin-bottom: 1.4667em; position: relative; text-rendering: optimizelegibility;">
Serialize an object to a query string. Optionally override the default separator and assignment characters.</div>
<div style="color: #222222; font-family: Georgia, FreeSerif, Times, serif; font-size: 15px; line-height: 22px; margin-bottom: 1.4667em; position: relative; text-rendering: optimizelegibility;">
Example:</div>
<pre class="sh_sourceCode" style="background-attachment: initial; background-clip: initial; background-color: #f8f8f8; background-image: initial; background-origin: initial; border-bottom-color: rgb(232, 232, 232); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(232, 232, 232); border-left-style: solid; border-left-width: 6px; border-right-color: rgb(232, 232, 232); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(232, 232, 232); border-top-style: solid; border-top-width: 1px; color: #222222; font-family: Monaco, Consolas, 'Lucida Console', monospace; font-size: 0.95em; line-height: 22px; margin-bottom: 1.1em; margin-top: -0.5em; padding-bottom: 2em; padding-left: 1.2em; padding-right: 1.6em; padding-top: 2em; vertical-align: top;"><code style="font-family: Monaco, Consolas, 'Lucida Console', monospace; font-size: 0.95em; line-height: 1.5438em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">querystring<span class="sh_symbol" style="color: #333333;">.</span><span class="sh_function">stringify</span><span class="sh_symbol" style="color: #333333;">(</span><span class="sh_cbracket" style="color: #333333;">{</span> foo<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_string" style="color: #669900;">'bar'</span><span class="sh_symbol" style="color: #333333;">,</span> baz<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_symbol" style="color: #333333;">[</span><span class="sh_string" style="color: #669900;">'qux'</span><span class="sh_symbol" style="color: #333333;">,</span> <span class="sh_string" style="color: #669900;">'quux'</span><span class="sh_symbol" style="color: #333333;">],</span> corge<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_string" style="color: #669900;">''</span> <span class="sh_cbracket" style="color: #333333;">}</span><span class="sh_symbol" style="color: #333333;">)</span>
<span class="sh_comment" style="color: #666666;">// returns</span>
<span class="sh_string" style="color: #669900;">'foo=bar&baz=qux&baz=quux&corge='</span>
querystring<span class="sh_symbol" style="color: #333333;">.</span><span class="sh_function">stringify</span><span class="sh_symbol" style="color: #333333;">(</span><span class="sh_cbracket" style="color: #333333;">{</span>foo<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_string" style="color: #669900;">'bar'</span><span class="sh_symbol" style="color: #333333;">,</span> baz<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_string" style="color: #669900;">'qux'</span><span class="sh_cbracket" style="color: #333333;">}</span><span class="sh_symbol" style="color: #333333;">,</span> <span class="sh_string" style="color: #669900;">';'</span><span class="sh_symbol" style="color: #333333;">,</span> <span class="sh_string" style="color: #669900;">':'</span><span class="sh_symbol" style="color: #333333;">)</span>
<span class="sh_comment" style="color: #666666;">// returns</span>
<span class="sh_string" style="color: #669900;">'foo:bar;baz:qux'</span></code></pre>
<h3 id="querystring.parse" style="font-family: Georgia, FreeSerif, Times, serif; font-size: 1.5em; line-height: 1.0909em; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 2.225em; position: relative; text-rendering: optimizelegibility;">
querystring.parse(str, sep='&', eq='=')<a href="http://nodejs.org/docs/latest/api/querystring.html#querystring.parse" style="color: black; float: right; font-size: 0.8em; opacity: 0.3; text-decoration: none;">#</a></h3>
<div style="color: #222222; font-family: Georgia, FreeSerif, Times, serif; font-size: 15px; line-height: 22px; margin-bottom: 1.4667em; position: relative; text-rendering: optimizelegibility;">
Deserialize a query string to an object. Optionally override the default separator and assignment characters.</div>
<div style="color: #222222; font-family: Georgia, FreeSerif, Times, serif; font-size: 15px; line-height: 22px; margin-bottom: 1.4667em; position: relative; text-rendering: optimizelegibility;">
Example:</div>
<pre class="sh_sourceCode" style="background-attachment: initial; background-clip: initial; background-color: #f8f8f8; background-image: initial; background-origin: initial; border-bottom-color: rgb(232, 232, 232); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(232, 232, 232); border-left-style: solid; border-left-width: 6px; border-right-color: rgb(232, 232, 232); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(232, 232, 232); border-top-style: solid; border-top-width: 1px; color: #222222; font-family: Monaco, Consolas, 'Lucida Console', monospace; font-size: 0.95em; line-height: 22px; margin-bottom: 1.1em; margin-top: -0.5em; padding-bottom: 2em; padding-left: 1.2em; padding-right: 1.6em; padding-top: 2em; vertical-align: top;"><code style="font-family: Monaco, Consolas, 'Lucida Console', monospace; font-size: 0.95em; line-height: 1.5438em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">querystring<span class="sh_symbol" style="color: #333333;">.</span><span class="sh_function">parse</span><span class="sh_symbol" style="color: #333333;">(</span><span class="sh_string" style="color: #669900;">'foo=bar&baz=qux&baz=quux&corge'</span><span class="sh_symbol" style="color: #333333;">)</span>
<span class="sh_comment" style="color: #666666;">// returns</span>
<span class="sh_cbracket" style="color: #333333;">{</span> foo<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_string" style="color: #669900;">'bar'</span><span class="sh_symbol" style="color: #333333;">,</span> baz<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_symbol" style="color: #333333;">[</span><span class="sh_string" style="color: #669900;">'qux'</span><span class="sh_symbol" style="color: #333333;">,</span> <span class="sh_string" style="color: #669900;">'quux'</span><span class="sh_symbol" style="color: #333333;">],</span> corge<span class="sh_symbol" style="color: #333333;">:</span> <span class="sh_string" style="color: #669900;">''</span> <span class="sh_cbracket" style="color: #333333;">}</span></code></pre>
<h3 id="querystring.escape" style="font-family: Georgia, FreeSerif, Times, serif; font-size: 1.5em; line-height: 1.0909em; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 2.225em; position: relative; text-rendering: optimizelegibility;">
querystring.escape<a href="http://nodejs.org/docs/latest/api/querystring.html#querystring.escape" style="color: black; float: right; font-size: 0.8em; opacity: 0.3; text-decoration: none;">#</a></h3>
<div style="color: #222222; font-family: Georgia, FreeSerif, Times, serif; font-size: 15px; line-height: 22px; margin-bottom: 1.4667em; position: relative; text-rendering: optimizelegibility;">
The escape function used by <code style="background-attachment: initial; background-clip: initial; background-color: ghostwhite; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(222, 222, 222); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(222, 222, 222); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(222, 222, 222); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(222, 222, 222); border-top-style: solid; border-top-width: 1px; font-family: Monaco, Consolas, 'Lucida Console', monospace; font-size: 0.95em; line-height: 1.5438em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0px;">querystring.stringify</code>, provided so that it could be overridden if necessary.</div>
<h3 id="querystring.unescape" style="font-family: Georgia, FreeSerif, Times, serif; font-size: 1.5em; line-height: 1.0909em; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 1.5em; position: relative; text-rendering: optimizelegibility;">
querystring.unescape<a href="http://nodejs.org/docs/latest/api/querystring.html#querystring.unescape" style="color: black; float: right; font-size: 0.8em; opacity: 0.3; text-decoration: none;">#</a></h3>
<div style="color: #222222; font-family: Georgia, FreeSerif, Times, serif; font-size: 15px; line-height: 22px; margin-bottom: 1.4667em; position: relative; text-rendering: optimizelegibility;">
The unescape function used by <code style="background-attachment: initial; background-clip: initial; background-color: ghostwhite; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(222, 222, 222); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(222, 222, 222); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(222, 222, 222); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(222, 222, 222); border-top-style: solid; border-top-width: 1px; font-family: Monaco, Consolas, 'Lucida Console', monospace; font-size: 0.95em; line-height: 1.5438em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0px;">querystring.parse</code>, provided so that it could be overridden if necessary.</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-45866546409462605732011-12-02T04:39:00.001-08:002011-12-02T04:39:52.806-08:00Node.js<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div id="siteSub" style="background-color: white; display: inline; font-family: sans-serif; font-size: 12px; line-height: 19px; text-align: -webkit-auto;">
From Wikipedia, the free encyclopedia</div>
<div id="contentSub" style="background-color: white; color: #7d7d7d; font-family: sans-serif; font-size: 11px; line-height: 1.2em; margin-bottom: 1.4em; margin-left: 1em; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto; width: auto;">
(Redirected from <a href="http://en.wikipedia.org/w/index.php?title=Nodejs&redirect=no" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Nodejs">Nodejs</a>)</div>
<div id="contentSub" style="background-color: white; color: #7d7d7d; font-family: sans-serif; font-size: 11px; line-height: 1.2em; margin-bottom: 1.4em; margin-left: 1em; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto; width: auto;">
<br /></div>
<div id="contentSub" style="background-color: white; color: #7d7d7d; font-family: sans-serif; font-size: 11px; line-height: 1.2em; margin-bottom: 1.4em; margin-left: 1em; margin-right: 0px; margin-top: 0px; text-align: -webkit-auto; width: auto;">
<div style="color: black; font-size: 13px; line-height: 19px; margin-bottom: 0.5em; margin-top: 0.4em;">
<b>Node.js</b> is a <a href="http://en.wikipedia.org/wiki/Software_system" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Software system">software system</a> designed for writing <a href="http://en.wikipedia.org/wiki/Scalability" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Scalability">highly-scalable</a> internet applications, notably <a href="http://en.wikipedia.org/wiki/Web_server" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Web server">web servers</a>.<sup class="reference" id="cite_ref-0" style="line-height: 1em;"><a href="http://en.wikipedia.org/wiki/Nodejs#cite_note-0" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none; white-space: nowrap;">[1]</a></sup> Programs are written in<a href="http://en.wikipedia.org/wiki/JavaScript" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="JavaScript">JavaScript</a>, using <a href="http://en.wikipedia.org/wiki/Event-driven_architecture" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Event-driven architecture">event-driven</a>, <a href="http://en.wikipedia.org/wiki/Asynchronous_I/O" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Asynchronous I/O">asynchronous I/O</a> to minimize overhead and maximize scalability.<sup class="reference" id="cite_ref-1" style="line-height: 1em;"><a href="http://en.wikipedia.org/wiki/Nodejs#cite_note-1" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none; white-space: nowrap;">[2]</a></sup> Node.js consists of Google's <a href="http://en.wikipedia.org/wiki/V8_(JavaScript_engine)" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="V8 (JavaScript engine)">V8 JavaScript engine</a> plus several built-in libraries.</div>
<div style="color: black; font-size: 13px; line-height: 19px; margin-bottom: 0.5em; margin-top: 0.4em;">
Node.js was created by <a class="new" href="http://en.wikipedia.org/w/index.php?title=Ryan_Dahl&action=edit&redlink=1" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #ba0000; text-decoration: none;" title="Ryan Dahl (page does not exist)">Ryan Dahl</a> starting in 2009, and its growth is sponsored by <a href="http://en.wikipedia.org/wiki/Joyent" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Joyent">Joyent</a>, his employer.<sup class="reference" id="cite_ref-2" style="line-height: 1em;"><a href="http://en.wikipedia.org/wiki/Nodejs#cite_note-2" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none; white-space: nowrap;">[3]</a></sup><sup class="reference" id="cite_ref-Node.js_pushes_JavaScript_to_the_server-side_3-0" style="line-height: 1em;"><a href="http://en.wikipedia.org/wiki/Nodejs#cite_note-Node.js_pushes_JavaScript_to_the_server-side-3" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none; white-space: nowrap;">[4]</a></sup></div>
<div style="color: black; font-size: 13px; line-height: 19px; margin-bottom: 0.5em; margin-top: 0.4em;">
Similar environments written in other programming languages include <a href="http://en.wikipedia.org/wiki/Twisted_(software)" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Twisted (software)">Twisted</a> for <a href="http://en.wikipedia.org/wiki/Python_(programming_language)" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Python (programming language)">Python</a>, <a href="http://en.wikipedia.org/wiki/Perl_Object_Environment" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Perl Object Environment">Perl Object Environment</a> for <a href="http://en.wikipedia.org/wiki/Perl" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Perl">Perl</a>, <a href="http://en.wikipedia.org/wiki/Libevent" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Libevent">libevent</a> for <a href="http://en.wikipedia.org/wiki/C_(programming_language)" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="C (programming language)">C</a> and EventMachine for <a href="http://en.wikipedia.org/wiki/Ruby_(programming_language)" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Ruby (programming language)">Ruby</a>. Unlike most <a href="http://en.wikipedia.org/wiki/JavaScript" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="JavaScript">JavaScript</a>, it is not executed in a web browser, but is instead a form of <a href="http://en.wikipedia.org/wiki/Server-side_JavaScript" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Server-side JavaScript">server-side JavaScript</a>. Node.js implements some <a href="http://en.wikipedia.org/wiki/CommonJS" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="CommonJS">CommonJS</a> specifications.<sup class="reference" id="cite_ref-4" style="line-height: 1em;"><a href="http://en.wikipedia.org/wiki/Nodejs#cite_note-4" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none; white-space: nowrap;">[5]</a></sup> Unlike most JavaScript systems, it provides a <a class="mw-redirect" href="http://en.wikipedia.org/wiki/Read-eval-print_loop" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Read-eval-print loop">REPL</a> environment for interactive testing.</div>
<div style="color: black; font-size: 13px; line-height: 19px; margin-bottom: 0.5em; margin-top: 0.4em;">
</div>
<h2 style="background-attachment: initial; background-clip: initial; background-image: none; background-origin: initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; font-size: 19px; font-weight: normal; margin-bottom: 0.6em; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0.17em; padding-top: 0.5em; width: auto;">
<span class="mw-headline" id="Examples">Examples</span></h2>
<div style="margin-bottom: 0.5em; margin-top: 0.4em;">
This is a complete implementation of <a href="http://en.wikipedia.org/wiki/Hello_world_program" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Hello world program">hello world</a> as a <a href="http://en.wikipedia.org/wiki/Web_server" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Web server">HTTP Server</a> in Node.js:</div>
<div class="mw-geshi" dir="ltr" style="border-bottom-color: rgb(47, 111, 171); border-bottom-style: dashed; border-bottom-width: 1px; border-left-color: rgb(47, 111, 171); border-left-style: dashed; border-left-width: 1px; border-right-color: rgb(47, 111, 171); border-right-style: dashed; border-right-width: 1px; border-top-color: rgb(47, 111, 171); border-top-style: dashed; border-top-width: 1px; line-height: 1.1em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em; text-align: left;">
<div class="javascript source-javascript" style="font-family: monospace; line-height: normal;">
<pre class="de1" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; border-bottom-color: white; border-bottom-style: none; border-bottom-width: 0px; border-left-color: white; border-left-style: none; border-left-width: 0px; border-right-color: white; border-right-style: none; border-right-width: 0px; border-top-color: white; border-top-style: none; border-top-width: 0px; font-family: monospace, 'Courier New' !important; font: normal normal normal 1em/1.2em monospace; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: top;"><span class="kw2" style="color: #003366; font-weight: bold;">var</span> http <span class="sy0" style="color: #339933;">=</span> require<span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'http'</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
http.<span class="me1" style="color: #660066;">createServer</span><span class="br0" style="color: #009900;">(</span><span class="kw2" style="color: #003366; font-weight: bold;">function</span> <span class="br0" style="color: #009900;">(</span>request<span class="sy0" style="color: #339933;">,</span> response<span class="br0" style="color: #009900;">)</span> <span class="br0" style="color: #009900;">{</span>
response.<span class="me1" style="color: #660066;">writeHead</span><span class="br0" style="color: #009900;">(</span><span class="nu0" style="color: #cc0000;">200</span><span class="sy0" style="color: #339933;">,</span> <span class="br0" style="color: #009900;">{</span><span class="st0" style="color: #3366cc;">'Content-Type'</span><span class="sy0" style="color: #339933;">:</span> <span class="st0" style="color: #3366cc;">'text/plain'</span><span class="br0" style="color: #009900;">}</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
response.<span class="me1" style="color: #660066;">end</span><span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'Hello World<span class="es0" style="color: #000099; font-weight: bold;">\n</span>'</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
<span class="br0" style="color: #009900;">}</span><span class="br0" style="color: #009900;">)</span>.<span class="me1" style="color: #660066;">listen</span><span class="br0" style="color: #009900;">(</span><span class="nu0" style="color: #cc0000;">8000</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
console.<span class="me1" style="color: #660066;">log</span><span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'Server running at http://127.0.0.1:8000/'</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
</pre>
</div>
</div>
<div style="margin-bottom: 0.5em; margin-top: 0.4em;">
<br />This is a simple <a href="http://en.wikipedia.org/wiki/Transmission_Control_Protocol" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Transmission Control Protocol">TCP</a> server which listens on <a class="mw-redirect" href="http://en.wikipedia.org/wiki/TCP_and_UDP_port" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="TCP and UDP port">port</a> 7000 and <a href="http://en.wikipedia.org/wiki/Echo_(command)" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Echo (command)">echoes</a> 'hello' upon connection:</div>
<div class="mw-geshi" dir="ltr" style="border-bottom-color: rgb(47, 111, 171); border-bottom-style: dashed; border-bottom-width: 1px; border-left-color: rgb(47, 111, 171); border-left-style: dashed; border-left-width: 1px; border-right-color: rgb(47, 111, 171); border-right-style: dashed; border-right-width: 1px; border-top-color: rgb(47, 111, 171); border-top-style: dashed; border-top-width: 1px; line-height: 1.1em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em; text-align: left;">
<div class="javascript source-javascript" style="font-family: monospace; line-height: normal;">
<pre class="de1" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; border-bottom-color: white; border-bottom-style: none; border-bottom-width: 0px; border-left-color: white; border-left-style: none; border-left-width: 0px; border-right-color: white; border-right-style: none; border-right-width: 0px; border-top-color: white; border-top-style: none; border-top-width: 0px; font-family: monospace, 'Courier New' !important; font: normal normal normal 1em/1.2em monospace; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: top;"><span class="kw2" style="color: #003366; font-weight: bold;">var</span> net <span class="sy0" style="color: #339933;">=</span> require<span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'net'</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
net.<span class="me1" style="color: #660066;">createServer</span><span class="br0" style="color: #009900;">(</span><span class="kw2" style="color: #003366; font-weight: bold;">function</span> <span class="br0" style="color: #009900;">(</span>stream<span class="br0" style="color: #009900;">)</span> <span class="br0" style="color: #009900;">{</span>
stream.<span class="kw1" style="color: #000066; font-weight: bold;">write</span><span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'hello<span class="es0" style="color: #000099; font-weight: bold;">\r</span><span class="es0" style="color: #000099; font-weight: bold;">\n</span>'</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
stream.<span class="me1" style="color: #660066;">on</span><span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'end'</span><span class="sy0" style="color: #339933;">,</span> <span class="kw2" style="color: #003366; font-weight: bold;">function</span> <span class="br0" style="color: #009900;">(</span><span class="br0" style="color: #009900;">)</span> <span class="br0" style="color: #009900;">{</span>
stream.<span class="me1" style="color: #660066;">end</span><span class="br0" style="color: #009900;">(</span><span class="st0" style="color: #3366cc;">'goodbye<span class="es0" style="color: #000099; font-weight: bold;">\r</span><span class="es0" style="color: #000099; font-weight: bold;">\n</span>'</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
<span class="br0" style="color: #009900;">}</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
stream.<span class="me1" style="color: #660066;">pipe</span><span class="br0" style="color: #009900;">(</span>stream<span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
<span class="br0" style="color: #009900;">}</span><span class="br0" style="color: #009900;">)</span>.<span class="me1" style="color: #660066;">listen</span><span class="br0" style="color: #009900;">(</span><span class="nu0" style="color: #cc0000;">7000</span><span class="br0" style="color: #009900;">)</span><span class="sy0" style="color: #339933;">;</span>
</pre>
</div>
</div>
<h2 style="background-attachment: initial; background-clip: initial; background-image: none; background-origin: initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; font-size: 19px; font-weight: normal; margin-bottom: 0.6em; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0.17em; padding-top: 0.5em; width: auto;">
<span class="editsection" style="float: right; font-size: 13px; margin-left: 5px;">[<a href="http://en.wikipedia.org/w/index.php?title=Node.js&action=edit&section=2" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Edit section: Community">edit</a>]</span><span class="mw-headline" id="Community">Community</span></h2>
<div style="margin-bottom: 0.5em; margin-top: 0.4em;">
Node.js has a active developer community primarily centered on two mailing lists, <a class="external text" href="http://groups.google.com/group/nodejs" rel="nofollow" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(data:image/png; background-origin: initial; background-position: 100% 50%; background-repeat: no-repeat no-repeat; color: #3366bb; padding-right: 13px; text-decoration: none;">nodejs</a> and <a class="external text" href="http://groups.google.com/group/nodejs-dev" rel="nofollow" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(data:image/png; background-origin: initial; background-position: 100% 50%; background-repeat: no-repeat no-repeat; color: #3366bb; padding-right: 13px; text-decoration: none;">nodejs-dev</a>, and the <a class="mw-redirect" href="http://en.wikipedia.org/wiki/IRC" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="IRC">IRC</a> channel #node.js on <a href="http://en.wikipedia.org/wiki/Freenode" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;" title="Freenode">freenode</a>. The community gathers at<a class="external text" href="http://www.nodeconf.com/" rel="nofollow" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(data:image/png; background-origin: initial; background-position: 100% 50%; background-repeat: no-repeat no-repeat; color: #3366bb; padding-right: 13px; text-decoration: none;">NodeConf</a>, an annual developer conference focused on Node.js.<sup class="reference" id="cite_ref-5" style="line-height: 1em;"><a href="http://en.wikipedia.org/wiki/Nodejs#cite_note-5" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none; white-space: nowrap;">[6]</a></sup></div>
</div>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com9tag:blogger.com,1999:blog-4467336557173928576.post-55559232547894967062011-12-02T04:36:00.001-08:002011-12-02T04:37:48.383-08:00Why Everyone Is Talking About Node<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #474747; font-family: Arial, Helvetica, sans-serif; font-size: 13px; line-height: 21px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto; vertical-align: baseline;">
On the 20th floor of a San Francisco skyscraper, a handful of developers are working on a new technology that’s changing the way real-time web apps are built and how they scale.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #474747; font-family: Arial, Helvetica, sans-serif; font-size: 13px; line-height: 21px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto; vertical-align: baseline;">
This technology, called <a href="http://mashable.com/tag/node.js" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;">Node.js</a>, is being hailed as “the new Ruby on Rails” by some in the developer community. But it’s not a magic bullet, nor is it appropriate for all programming scenarios.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #474747; font-family: Arial, Helvetica, sans-serif; font-size: 13px; line-height: 21px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto; vertical-align: baseline;">
<a href="http://mashable.com/tag/joyent" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;">Joyent</a>, an SF-based cloud software company, is sponsoring the growth and development of Node. It employs Node creator Ryan Dahl, hosts events and <a href="http://mashable.com/2011/03/02/joyent-node/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;">creates tools</a> for the growing Node community. Recently, <em style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">Mashable</em>visited Joyent to see demos from three startups that are using Node to build web and mobile apps for consumers.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #474747; font-family: Arial, Helvetica, sans-serif; font-size: 13px; line-height: 21px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto; vertical-align: baseline;">
</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
In the process, we learned a lot about how and why Node works for the real-time web — and how Node is changing the way the developer community creates the Internet as we know it.</div>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<h3 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 24px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
What Makes Node Different</h3>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node had a watershed year in 2010, and it’s shaping up to be as popular as Ruby on Rails among developers. Since the framework was built for the commonly used JavaScript, the barriers to entry are remarkably low, and the reasons for choosing Node to build apps — especially low-latency, real-time apps — are increasingly compelling.</div>
<br />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #474747; font-family: Arial, Helvetica, sans-serif; font-size: 13px; line-height: 21px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto; vertical-align: baseline;">
</div>
<div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Then there’s the community. The Ruby community has been criticized for being exclusive and harsh. The Node community provides a welcome contrast and embodies the spirit of many other open-source communities. Again, the framework’s JavaScript roots means that it appeals to the less hacker-ish web designer who might be dabbling in web app development as much as it appeals to longtime, hardcore hackers who simply want a better way to build real-time apps.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
We asked each of the three startups giving demos at Joyent: Why choose Node?</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
The common wisdom among many developers is that there is no single right language or framework that should and must be used for all web apps. But based on what we heard from these startups, Node is increasingly being seen as a “best solution” for a certain type of application.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
According to Tom Hughes-Croucher, a recent Joyent hire who is writing the <a href="http://mashable.com/2011/03/03/node-book/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;">first O’Reilly book on Node</a>, “Node has popularized event-driven programming.” With event-driven programming, Hughes-Croucher explains, “The actual amount of resources you use is much smaller, and you can get a lot more out of fewer servers.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node is all about making event-driven, low-latency, concurrent apps. Erlang, the language that powers Facebook’s chat server, uses the same model. <a href="http://www.tornadoweb.org/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">Tornado</a>, a concurrent server for Python that powers FriendFeed, was an attempt at this, too. But Node has one advantage over technologies like Erlang and Tornado: “None of that was too accessible,” says Hughes-Croucher. “Node takes a language people know very well — Javascript — and makes it available to do server programming, as well.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
In traditional languages and frameworks, the communication inside the app between the web server and the database is the most time-intensive part of the transaction. Node makes a much smaller footprint on your web server. It allocates web server resources on an as-needed basis, not pre-allocating a large chunk of resources for each user. For example, Apache might assign 8MB to a user, while Node assigns 8KB.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“The way that Node is more efficient on servers is by not allocating resources to things while it waits,” says Hughes-Croucher. “Say you have to talk to the database, and that’s going to take 50ms to respond. Instead of assigning all of the processing resources for that 50ms wait, it just uses a placeholder. When the database responds, then it allocates the resources needed to process. That means it’s totally possible to do a lot more requests at once, because you only allocate the server resources when you need to use them, not while you are waiting on databases.”</div>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<h3 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 24px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node’s Explosive Growth</h3>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Unlike PHP or Ruby, Node has yet to appear as the technological face of a popular, mass-adopted web service like Twitter, WordPress or Facebook.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Rather, Node took off in the imaginations of programmers, organically becoming the quirky new tech that was on the tip of every tongue. First, devs asked if you’d heard of it; then, they started asking if you’d tried it or built anything with it.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
As you can see from these GitHub reports, both the number of committers and the number of commits to Node core really took off, and there are no signs of Node’s growth slowing down in the dev community.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
<br /></div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Commits and committers to Node on GitHub peaked in the fall of 2010, but developers’ conversations around Node have really just started to pick up steam since the beginning of 2011. Here’s a graph showing Twitter conversations around Node; you’ll notice a few spikes throughout the fall of 2010, and more consistent conversations occurring in 2011.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
If you look at Rails and Node on GitHub and compare the traffic,” says Hughes-Croucher, “Rails had 270,000 views over the past three months. Node has 325,000, and it’s only going up… it’s exploding.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
There have been “it” technologies in the past, and the current vogue is Ruby on Rails. So what makes devs think Node is the heir apparent?</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“Node is going to become the next big thing for a few reasons,” said Hughes-Croucher. “Everyone wants to do way more powerful apps — things like Google Instant and Facebook. People are expected to support millions of users on a ton of devices in real time. These are the expectations people have of applications now. And if you did that with traditional frameworks, it would take forever, and the hardware would cost millions of dollars.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“The point of Node is that it’s really fast, it’s really easy to scale, and the Javascript aspect means it’s really easy to build.”</div>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<h3 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 24px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node for Real-Time Voice</h3>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Igal Perelman is the VP of product for <a href="http://voxer.com/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">Voxer</a>, an iOS app that aims to “make audio sexy again.” It functions a bit like a walkie-talkie, a bit like a group IM app and a bit like a social/location consumer app.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“There is a huge reason why kids love to use walkie-talkies. It’s fun and immediate,” said Perelman. “We took that basic use case and improved it a lot.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
The user pushes a button, starts talking, and the message is immediately sent to the app user on the other end. Both parties can listen and talk simultaneously. Chat requests come through as push notifications, allowing the users to choose whether or not to join the chat.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Users can also re-listen to messages in case they need clarification or missed part of a message, like rewinding a video. Another cool feature: The app supports group chats with unlimited numbers of participants.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Finally, it’s entirely free.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Voxer uses Node because the low latency allows for near-instant transfer of audio data. Says Perelman: “Node was very crucial to this, because the audio needed to be live. And Node allows us to maintain a large number of connections with very low latency. It was a quite easy decision.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Voxer’s VP of technology, Matt Ranney, told us (via the app itself, of course), “This is our third iteration trying to do live voice. We first tried C++ for performance reasons, but it was too complicated, too hard to wrangle. Next, we chose Python. It was great, but unfortunately, the Python virtual machine is incredibly slow.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“So we’ve gone to the opposite extreme. In our third version, we’ve done it in Node, and we have the best of both worlds. We have the high-level language of Javascript and the high performance of the [Google's V8 JavaScript engine's] virtual machine.”</div>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<h3 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 24px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node for Gaming</h3>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
One of the <a href="http://mashable.com/2010/06/30/hackathons/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;">hackathons we followed this year</a> was <a href="http://nodeknockout.com/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">Node Knockout</a>, a 48-hour contest to see who in the world can build the best, most complete, most interesting Node apps on a very tight deadline.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
The popularity winner for the 2010 contest was Scrabb.ly, a massively multiplayer online version of Scrabble. The game plays in real time, and the map of all the tiles is sprawling to gargantuan proportions.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
The team built the game in two days and has since made <a href="http://wordsquared.com/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">a company</a> out of the project.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
On the flipside, “Rails Rumble [a similar, Ruby-on-Rails-flavored hackathon] has been around for four or five years, and only one company has come out of it,” says Fortnight Labs and Node Knockout co-founder Gerad Suyderhoud. “We had a company in our first year. Because Node is such a great technology for real-time web apps, you see a lot more games, so the results are a lot more fun.” The next Node Knockout is in August 2011.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Suyderhoud and co-founder Visnu Pitiyanuvath’s entry in the 2009 Rails Rumble was <a href="http://www.lazeroids.com/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">Lazeroids</a>, but they discovered that building a real-time game in RoR was “too hard.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
When it comes to real-time games, says Suyderhoud, “There’s really not a lot that’s competing with [Node]. The other technologies just aren’t as good at doing real time. They’re backed in older frameworks. Node was designed from the ground up for real time and to be easy to use. Other technologies would take forever to do the same things.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“You have this giant ecosystem of Javascript that’s perfect for real time,” he adds.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
And as far as community is concerned, Suyderhoud says, “it’s amazing how inclusive it is. I’ve never seen such good support. For Node Knockout, it was some people’s first time using Node. We didn’t provide a lot of support, but we got really lucky. A lot of people who had no vested interest and were not participants stepped up and helped people solve their problems over the weekend, in chat channels and over Twitter. I was definitely not expecting that.”</div>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<h3 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 24px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node for Collaboration</h3>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
<a href="https://gomockingbird.com/" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">Mockingbird</a> is more a tool for web designers than a true consumer app, and it allows devs and designers to rapidly create wireframes. The interesting thing about Mockingbird is that this Node.js app is already making serious money for its creators.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Basically, Mockingbird is a tool for collaborative drawing and real-time communication between designers and clients. It took the founders just months to take the app from concept to a working beta.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
“We’ve been around since November of 2009 and launched our paid product November 2010,” says CTO and co-founder Saikat Chakrabarti. “We’re doing much better than we thought. We thought we’d be struggling entrepreneurs for a long time, but we’re very much in the green.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
The app currently has 60,000 users and hosts more than 100,000 projects.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Says Chakrabarti: “I tried to do the app in Twisted and Tornado at the time, and Node was by far the easiest… A lot of people and companies are very invested in this.”</div>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<h3 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 24px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Node for the Future</h3>
<hr style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-color: initial; border-color: initial; border-left-style: none; border-right-style: none; border-style: initial; border-top-style: none; border-width: initial; height: 1px; margin-bottom: 24px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" />
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
Time will prove whether Node is that next big thing, but one thing was agreed upon by all parties at this roundtable demo session: Node needs a Twitter, a Facebook or some other big, consumer-friendly, mass-adopted app to make the mainstream tech community take notice.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
However, as soon as middle managers get wind of Node, it runs the risk of developing a bubble. An employment bubble would surely be followed by an employment crash, which would likely be perceived as the “downfall of Node.”</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
A misunderstanding of the technology is also a risk. Former Twitter engineer Alex Payne’s claim that <a href="http://al3x.net/2009/04/04/reasoned-technical-discussion.html" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #1e598e; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" target="_blank">Ruby was slow</a> continues to haunt general conversations about Ruby to this day.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
It’s not our intention to inflate anyone’s expectations of Node. And we’re certainly not advocating its use for all programming projects. However, we do think that Node is an interesting, accessible and efficient technology for real-time applications, and we’d love to see what comes of this framework.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
We’ll especially be keeping an eye out for “the Twitter of Node” — both to critically examine how the framework performs under pressure and to keep an eye out for hype.</div>
<div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 18px; margin-top: 18px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">
<em style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">Stay tuned for</em> Mashable<em style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">‘s ongoing coverage of Node, including one-on-one interviews and code snippets to get you started.</em></div>
<div>
<em style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"><a href="http://mashable.com/2011/03/10/node-js/">posted from this article</a></em></div>
</div>
<br />
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com1tag:blogger.com,1999:blog-4467336557173928576.post-63154387470960596632011-11-30T22:30:00.001-08:002011-11-30T22:32:10.193-08:00Google Maps Query String Parameters<div dir="ltr" style="text-align: left;" trbidi="on">
<span class="Apple-style-span" style="background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif;"><span class="Apple-style-span" style="font-size: xx-small;">The following is a list of query string parameters that can be passed to Google Maps. These arguments are helpful if you want to get Google Maps to display driving directions, which are not available under the API.</span></span><br />
<span class="Apple-style-span" style="background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif;"><span class="Apple-style-span" style="font-size: xx-small;"><br /></span></span><br />
<br />
<table border="0" style="background-color: white; font-family: Arial, Helvetica, sans-serif; vertical-align: top;"><tbody>
<tr><td style="vertical-align: top;" width="90px"><h2 style="color: #636363; font-family: 'Arial Black', arial; font-size: 14px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">
<span class="Apple-style-span" style="font-size: xx-small;">Query</span></h2>
</td><td style="vertical-align: top;" width="510px"><h2 style="color: #636363; font-family: 'Arial Black', arial; font-size: 14px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">
<span class="Apple-style-span" style="font-size: xx-small;">Translation</span></h2>
</td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">q=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“q” stands for “query” and anything passed in this parameter is treated as if it had been typed into the query box on the maps.google.com page.<br />EX.</span><br />
<span class="Apple-style-span" style="font-size: xx-small;">http://maps.google.com/?q=New+York</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">near=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“near” can be used as the location part of a query instead of putting the entire string into <strong>q=. </strong>Also needed/useful for disambiguation.<br />EX.</span><br />
<span class="Apple-style-span" style="font-size: xx-small;">http://maps.google.com/?q=shelton;near=new+york</span><br />
<span class="Apple-style-span" style="font-size: xx-small;">http://maps.google.com/?q=shelton;near=seattle</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">g=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“g” is an address or location that provides extra context for the “q” parameter. Google Maps stores the last run search here, but if it is the first search it can only contain your starting location. This is a potential information leak, so make sure you do actually mean to share the content of this parameter.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">mrt=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“mrt” specifies a type of search. The default is blank, which searches for everything. Other options are:</span><br />
<ul>
<li><span class="Apple-style-span" style="font-size: xx-small;">mrt=yp – Yellow pages</span></li>
<li><span class="Apple-style-span" style="font-size: xx-small;">mrt=realestate — real estate listings</span></li>
<li><span class="Apple-style-span" style="font-size: xx-small;">mrt=ds — Related maps</span></li>
<li><span class="Apple-style-span" style="font-size: xx-small;">mrt=websearch — local web pages (synonym for ‘yp’ ?)</span></li>
<li><span class="Apple-style-span" style="font-size: xx-small;">mrt=loc — Locations search</span></li>
</ul>
<span class="Apple-style-span" style="font-size: xx-small;">Many uses will require the ‘q’ option and/or the ‘near’ option<br />EX.</span><br />
<span class="Apple-style-span" style="font-size: xx-small;">http://maps.google.com/?q=phoenix&mrt=yp&near=tempe</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">start=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“start” skips the first (start-1) matches.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">num=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“num” displays, at most, the given number of matches. The valid range is 0 to 20.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">ll=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“ll” stands for Latitude,longitude of a Google Map center – Note that the order has to be latitude first, then longitude and it has to be in decimal format.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">sll=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“sll” Latitude,longitude of the point from which the business search should be performed.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">spn=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“spn” Approximate lat/long span. The zoom level will be adjusted to fit if there’s no <strong>z=</strong> parameter.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><span class="Apple-style-span" style="font-size: xx-small;"><strong>latlng</strong><strong>=</strong></span></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“latlng” takes three numbers separated by commas. The first two numbers (presumably representing latitude and longitude multiplied by 1000000) are ignored. The third number seems to be a Google internal “Company ID” number for a particular business.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><span class="Apple-style-span" style="font-size: xx-small;"><strong>cid</strong><strong>=</strong></span></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“cid” is similar to “latlng,” but generating a different map size. It takes three numbers separated by commas. The first two numbers (presumably representing latitude and longitude multiplied by 1000000) are ignored. The third number seems to be a Google internal “Company ID” number for a particular business.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">geocode=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“geocode” is a concatination of “geocode” encoded values for waypoints used in directions.<strong></strong></span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">radius=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“radius” localizes results to a certain radius. Requires “sll” or similar center point to work.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">t=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“t” is Map Type. The available options are “m” map, “k” satellite, “h” hybrid, “p” terrain.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">z=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“z” sets the zoom level.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">layer=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“layer” Activates overlay. Current option is “t” traffic.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">lci=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“lci” activates layers of tiles and needs to be comma-separated.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">view=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“view” can be used to select text view (view=text) or the normal map view (view=map).</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">saddr=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“saddr” source address. Use this when asking for driving directions.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">daddr=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“daddr” Destination address(es). Use this when asking for driving directions.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">mrad=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“mrad” gives you additional destination address.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">dirflg=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“dirflg” is the route type: dirflg=h Switches on “Avoid Highways” route finding mode. dirflg=t Switches on “Avoid Tolls” route finding mode. dirflg=r Switches on “Public Transit” – only works in some areas. dirflg=w Switches to walking directions – still in beta.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">via=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“via” gives a comma separated list of intermediate addresses for directions, that should be ‘via points’.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">doflg=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“doflg” Distance Units. (Defaults to prevalent units in country of origin.) doflg=ptk outputs directions in metric (km) and doflg=ptm outputs directions in imperial (miles).</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">cbll=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“cbll” is latitude,longitude for Street View.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">cbp=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“cbp” Street View window that accepts 5 parameters: 1) Street View/map arrangement, 11=upper half Street View and lower half map, 12=mostly Street View with corner map 2) Rotation angle/bearing (in degrees) 3) Tilt angle, -90 (straight up) to 90 (straight down) 4) Zoom level, 0-2 5) Pitch (in degrees) -90 (straight up) to 90 (straight down), default 5</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">panoid=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“panoid” is the panorama ID, which is the ID of the current nearby panorama object in Street View.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">hl=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“hl” stands for “host language”.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">om=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“om” stands for “overview map.” The presence of this parameter with a value other than 1 causes the overview map to be closed. If the parameter is omitted, or present with the value 1, then the overview map is open.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">ie=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“ie” stands for “input encoding” and can be used to specify the input character encoding set.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">oe=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“oe” stands for “output encoding” and can be used to specify the input character encoding set.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">output=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“output” is for output format (blank is default).</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">f=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“f” stands for “form” and controls the style of query form to be displayed. f=d Displays the “directions” form (two input boxes: from, to). f=l Displays the “local” form (two input boxes: what, where). f=q (or no parameter) The default search form is displayed (single input).</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">pw=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“pw” stands for “print window.” It activates the print mode and initiates printing. Example, pw=2.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">iwloc=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“iwloc” stands for “info window location” and specifies where the infowindow will be displayed. In a business search iwloc=A to iwloc=J will open the info window over the corresponding business marker, and iwloc=near will place it over the big green arrow if that’s currently displayed. iwloc=addr can be used on map search to explicitly request the info window to be open on the address, but that’s the default anyway. Directions search supports iwloc=start, iwloc=end and iwloc=pause1</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">iwd=1</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“iwd” stands for “info window display” and specifies that the infowindow displayed (<strong>iwloc=</strong>) will be a detailed (expanded) view.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><span class="Apple-style-span" style="font-size: xx-small;"><strong>iwstate1</strong><strong>=</strong></span></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">iwstate1=ssaddfeatureinstructioncard Specifies that the infowindow is in add place mode. Use with ssp=addf and iwloc=SS. iwstate1=sscorrectthiscard Specifies the infowindow is in edit mode. iwstate1=sscorrectthiscard:ssmovemarkercard The infowindow is in Move marker mode, with the marker bouncing and draggable. iwstate1=sscorrectthiscard:ssedithistorycard The infowindow is in View history mode, displaying a graphical list of marker moves.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">msa=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“msa” is involved in My Maps processing. It does nothing without the “/ms” and “/ms” does nothing without the msa=. msa=0 Used with msid= to show a particular My Map.<br />msa=b Activates the “My Maps” sidebar when used in conjunction with “maps.google.com/ms”. msa=1 shows the My Maps tab directly (like msa=b did). msa=2 Jumps directly to create new My Map form.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">msid=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“msid” specifies a My Maps identifier. When used in conjunction with “maps.google.com/ms” and msa=0, the corresponding My Map is displayed.</span></td></tr>
<tr><td style="vertical-align: top;" valign="top" width="90px"><strong><span class="Apple-style-span" style="font-size: xx-small;">vp=</span></strong></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“vp” stands for “view point” and the presence of this parameter causes maps.google.com to switch into Copyright Service mode. Instead of returning the html that draws a map, it returns information about the copyright ownership in Javascript format. The vp= parameter specifies the viewpoint (i.e. the centre of the map). Copyright Service only works when the spn= and z= parameters are also supplied, indicating the span and the zoom. Optional parameters are t=, which specifies the map type, and key= which specifies the API key of the site performing the request.<br /></span><div style="color: #333333; font-size: 13px; margin-bottom: 20px; margin-left: 0px; margin-right: 0px; margin-top: 20px; text-align: left;">
<table style="vertical-align: top;"><tbody>
<tr><td style="vertical-align: top;" valign="top" width="90px"><span class="Apple-style-span" style="font-size: xx-small;"><strong>sspn</strong><strong>=</strong></span></td><td style="vertical-align: top;" width="510px"><span class="Apple-style-span" style="font-size: xx-small;">“sspn” stands for “Screen span”. Map bounds dimensions in Degrees, to calculate this use:<code style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed;">newGLatLng(map.getBounds().getNorthEast().lat() − map.getBounds().getSouthWest().lat(),map.getBounds().getNorthEast().lng() − map.getBounds().getSouthWest().lng()).toUrlValue()</code></span></td></tr>
</tbody></table>
</div>
<div style="color: #333333; font-size: 13px; text-align: left;">
<span class="Apple-style-span" style="font-size: xx-small;">Thanks to <a href="http://mapki.com/wiki/Google_Map_Parameters" style="color: #3c6ab3; text-decoration: none;">Google Maps Parameters Guide</a> from MapKi for this great resource!</span></div>
</td></tr>
</tbody></table>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com22tag:blogger.com,1999:blog-4467336557173928576.post-41993955614579813222011-11-30T22:25:00.001-08:002011-11-30T22:28:52.104-08:00Android: Deserialize both XML and JSON<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0.8em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">
When I first started learning Android, I was curious in making service calls and handling the results. Naturally, I wanted to see code snippets involving</div>
<ul style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0.4em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">
<li style="list-style-position: outside; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">parsing XML</li>
<li style="list-style-position: outside; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">deserializing JSON</li>
</ul>
<div style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0.8em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">
To my surprise, most snippets I found only demonstrated XML parsing, with fewer demonstrating JSON deserialization. Therefore, I decided to post these brief snippets in hopes they are useful to folks.</div>
<div style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0.8em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">
We’ll use a simple Employee class as an example. If you are familiar with the term DTO, <em style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;">data transfer object</em>, this Employee class represents a simple DTO. The Java source code is as follows:</div>
<blockquote class="tr_bq">
<pre style="text-align: -webkit-auto;">public class Employee {
public long Id;
public long DeptId;
public long SalaryGradeId;
public String FirstName;
public String LastName;
public String Email;
public String Phone;
public String Title;
public boolean TakesLongLunches;
}</pre>
</blockquote>
<br />
<span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">And we’ll use the following ResourceHelper class to request a list of employees:</span><br />
<pre style="text-align: -webkit-auto;">package com.demo.helpers;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.impl.client.DefaultHttpClient;
public class ResourceHelper {
public static String loadManySerialized(String url)
{
HttpClient httpclient = new DefaultHttpClient();
// Prepare a request object
HttpGet httpget = new HttpGet(url);
// Execute the request
HttpResponse response;
String result = null;
try {
response = httpclient.execute(httpget);
// Get hold of the response entity
HttpEntity entity = response.getEntity();
// If the response does not enclose an entity, there is no need
// to worry about connection release
if (entity != null) {
// A Simple Response Read
InputStream instream = entity.getContent();
result = convertStreamToString(instream);
// Closing the input stream will trigger connection release
instream.close();
}
} catch (ClientProtocolException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return result;
}
private static String convertStreamToString(InputStream is) {
/*
* To convert the InputStream to String we use the BufferedReader.readLine()
* method. We iterate until the BufferedReader return null which means
* there's no more data to read. Each line will appended to a StringBuilder
* and returned as String.
*/
BufferedReader reader = new BufferedReader(new InputStreamReader(is), 8192);
StringBuilder sb = new StringBuilder();
String line = null;
try {
while ((line = reader.readLine()) != null) {
sb.append(line + "\n");
}
} catch (IOException e) {
e.printStackTrace();
} finally {
try {
is.close();
} catch (IOException e) {
e.printStackTrace();
}
}
return sb.toString();
} </pre>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: monospace; white-space: pre;">}</span></blockquote>
<br />
<span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">And here are two calls to ResourceHelper; one requesting the response in XML format, and the other requesting the response in JSON:</span><br />
<pre style="text-align: -webkit-auto;">String XMLSerializedResources = ResourceHelper.loadManySerialized("http://demos.brianbuikema.com/apps/soa_services/employees?format=XML"); </pre>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: monospace; white-space: pre;">String JSONSerializedResources = ResourceHelper.loadManySerialized("http://demos.brianbuikema.com/apps/soa_services/employees?format=JSON");</span></blockquote>
<div style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0.8em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">
For reference, <a href="http://demos.brianbuikema.com/apps/soa_services/employees" style="color: #0071bb; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: none; outline-width: initial; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" target="_blank">here is a web page displaying the actual employee records</a>.</div>
<span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">Next, we’ll parse the XML list within the Employee Repository with the help of an XMLHelper class (see line 24). The XMLHelper class, also shown below, calls the ResourceHelper class we discussed earlier.</span><br />
<br />
<pre style="text-align: -webkit-auto;">package com.demo.domainmodel.repository;
import java.io.IOException;
import java.util.ArrayList;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
import com.demo.domainmodel.Employee;
import com.demo.helpers.XmlHelper;
public class EmployeeRepository
{
public static ArrayList<Employee> loadMany(String url)
{
int parserEvent = -1;
XmlPullParser parser = null;
ArrayList<Employee> items = new ArrayList<Employee>();
String tag = "";
Employee item = null;
try {
// calls service (referenced in url) to request XML serialized data
parser = XmlHelper.loadData(url);
parserEvent = parser.getEventType();
while (parserEvent != XmlPullParser.END_DOCUMENT) {
switch(parserEvent) {
case XmlPullParser.START_TAG:
tag = parser.getName();
if (tag.compareTo("Employee") == 0){
item = new Employee();
}
break;
case XmlPullParser.END_TAG:
tag = parser.getName();
if (tag.compareTo("Employee") == 0){
items.add(item);
}
break;
case XmlPullParser.TEXT:
String text = parser.getText();
if (text.trim().length() == 0) break;
if (tag.compareTo("Id") == 0){
item.Id = Integer.parseInt(text);
}
else if (tag.compareTo("DeptId") == 0){
item.DeptId = Integer.parseInt(text);
}
else if (tag.compareTo("SalaryGradeId") == 0){
item.SalaryGradeId = Integer.parseInt(text);
}
else if(tag.compareTo("FirstName") == 0){
item.FirstName = text;
}
else if(tag.compareTo("LastName") == 0){
item.LastName = text;
}
else if(tag.compareTo("Email") == 0){
item.Email = text;
}
else if(tag.compareTo("Phone") == 0){
item.Phone = text;
}
else if(tag.compareTo("Title") == 0){
item.Title = text;
}
else if(tag.compareTo("TakesLongLunches") == 0){
item.TakesLongLunches = Boolean.parseBoolean(text);
}
break;
}
parserEvent = parser.next();
}
} catch (XmlPullParserException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
// return de-serialized list of employees
return items;
}
}
package com.demo.helpers;
import java.io.*;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
import org.xmlpull.v1.XmlPullParserFactory;
public class XmlHelper {
public static XmlPullParser loadData(String url) throws XmlPullParserException, IOException
{
String xmlData = ResourceHelper.loadManySerialized(url);
XmlPullParserFactory parserFactory = XmlPullParserFactory.newInstance();
XmlPullParser parser = parserFactory.newPullParser();
parser.setInput(new StringReader(xmlData));
return parser;
} </pre>
<span class="Apple-style-span" style="font-family: monospace; white-space: pre;">}</span><br />
<span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">To call the EmployeeRepository to obtain an actual list of Employee objects, simply use the following:</span><br />
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: monospace; white-space: pre;">ArrayList<Employee> employees = EmployeeRepository.loadMany("http://demos.brianbuikema.com/apps/soa_services/employees?format=XML");</span></blockquote>
<br />
<span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">And finally, we’ll deserialize the JSON list. </span><strong style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">Please pay special attention</strong><span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; text-align: -webkit-auto;"> as the Employee class has been modified to do its own deserialization/serialization. I use a static method </span><em style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">deserializeArray(…)</em><span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; text-align: -webkit-auto;"> from within the Employee class, passing it the JSON results from the call to</span><em style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">ResourceHelper.loadManySerialized(…)</em><span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">:</span><br />
<pre style="text-align: -webkit-auto;">package com.hd.domainmodel;
import java.util.ArrayList;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
public class Employee {
public long Id;
public long DeptId;
public long SalaryGradeId;
public String FirstName;
public String LastName;
public String Email;
public String Phone;
public String Title;
public boolean TakesLongLunches;
public Employee() {
}
public Employee(JSONObject obj) throws JSONException {
deserializeFromObj(obj);
}
public Employee(String serializedObj) throws JSONException {
deserialize(serializedObj);
}
public void deserialize(String serializedObj) throws JSONException {
JSONObject obj = new JSONObject(serializedObj);
deserializeFromObj(obj);
}
public void deserializeFromObj(JSONObject obj) throws JSONException {
this.Id = obj.getLong("Id");
this.DeptId = obj.getLong("DeptId");
this.SalaryGradeId = obj.getLong("SalaryGradeId");
this.FirstName = obj.getString("FirstName");
this.LastName = obj.getString("LastName");
this.Email = obj.getString("Email");
this.Phone = obj.getString("Phone");
this.Title = obj.getString("Title");
this.TakesLongLunches = Boolean.parseBoolean(obj.getString("TakesLongLunches"));
}
public String serialize() throws JSONException {
return serializeToObj().toString();
}
public JSONObject serializeToObj() throws JSONException {
JSONObject serializedObj = new JSONObject();
serializedObj.put("Id", this.Id);
serializedObj.put("DeptId", this.DeptId);
serializedObj.put("SalaryGradeId", this.SalaryGradeId);
serializedObj.put("FirstName", this.FirstName);
serializedObj.put("LastName", this.LastName);
serializedObj.put("Email", this.Email);
serializedObj.put("Phone", this.Phone);
serializedObj.put("Title", this.Title);
serializedObj.put("TakesLongLunches", this.TakesLongLunches);
return serializedObj;
}
public static ArrayList<Employee> deserializeArray(String serializedArray) throws JSONException {
JSONArray jsonObjs = new JSONArray(serializedArray);
ArrayList<Employee> employees = new ArrayList<Employee>();
for (int i=0; i<jsonObjs.length(); i++) {
JSONObject employee = jsonObjs.getJSONObject(i);
employees.add(new Employee(employee));
}
return employees;
} </pre>
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: monospace; white-space: pre;">}</span></blockquote>
<span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px;">o retrieve a list of employee objects, we’ll call the </span><em style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: -webkit-auto;">Employee.deserializeArray(…)</em><span class="Apple-style-span" style="background-color: white; color: #4e4e4e; font-family: 'Segoe UI', Calibri, 'Myriad Pro', Myriad, 'Trebuchet MS', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 19px; text-align: -webkit-auto;">, passing it the serialized String obtained by calling ResourceHelper.loadManySerialized(…).</span><br />
<blockquote class="tr_bq">
<span class="Apple-style-span" style="font-family: monospace; white-space: pre;">ArrayList<Employee> employees = Employee.deserializeArray(ResourceHelper.loadManySerialized("http://demos.brianbuikema.com/apps/soa_services/employees?format=JSON"));</span></blockquote>
<span class="Apple-style-span" style="font-size: x-small;"><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; text-align: -webkit-auto;">This</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; text-align: -webkit-auto;">article</span><span class="Apple-style-span" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; text-align: -webkit-auto;"> </span><span class="hps" style="background-color: whitesmoke; color: #333333; font-family: arial, sans-serif; text-align: -webkit-auto;">comes from <a href="http://blog.brianbuikema.com/">Brian Buikema</a></span></span><br />
<br />
<blockquote class="tr_bq">
</blockquote>
<blockquote class="tr_bq">
</blockquote>
<blockquote class="tr_bq">
</blockquote>
<blockquote class="tr_bq">
</blockquote>
<blockquote class="tr_bq">
</blockquote>
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com1tag:blogger.com,1999:blog-4467336557173928576.post-14077324567440595872011-01-28T21:40:00.000-08:002011-01-28T21:40:36.373-08:00"Module Has Not been Deployed" Tomcat 6.0<div dir="ltr" style="text-align: left;" trbidi="on">error seperti judul diatas sebenarnya merupakan bug antara IDE netbeans dengan pemberlakuan "Garbage Collection".<br />
kalau kita searching di google. maka saran2 yang kita dapatkan cukup ekstream.seperti :<br />
<ol style="text-align: left;"><li><b>mengganti menggunakan Glassfish server</b></li>
<li><b>merollback JDK kita menjadi versi sebelumnya</b></li>
<li><b>atau menggunakan manual start and shutdown service tomcat apache.</b></li>
</ol>sebenarnya masalah yang kita hadapi tidaklah terlalu rumit.<br />
error "modul has not been deployed" biasanya terjadi karena kegagalan apache tomcat server mendeploy web application yang kita buat, jadi yang kita trace adalah kegagalan itu. dan penyebabnya.<br />
biasanya penyebab terjadi nya error adalah :<br />
<ol style="text-align: left;"><li><b>bentrok service antara tomcat server dengan server selain itu ataupun dengan sesama tomcat server namun beda versi (karena tiap tomcat server bisa berjalan juga)</b></li>
<li><b>pengaturan JAVA_HOME dan PATH yang belum kita lakukan pada Environmental Variables</b></li>
<li><b>atau karena kesalahan setting pada project di Netbeans.</b></li>
</ol>solusi nya mudah saja.<br />
<b>cek saja point2 diatas. dan pastikan sudah selesai. jika sudah tinggal lakukan Clean & Build pada project kita. dan kemudian Run. maka akan berjalan dengan semestinya.</b><br />
<br />
<b> </b></div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com12tag:blogger.com,1999:blog-4467336557173928576.post-24824191162894578812011-01-28T09:33:00.000-08:002011-01-28T09:33:40.507-08:00Install Service Tomcat 7 Win<div dir="ltr" style="text-align: left;" trbidi="on">merunut dari posting saya tentang menjalankan tomcat 7.0 di sistem operasi berbasis windows.<br />
terbayang betapa repot nya jika saya harus menjalankan cmd dan melakukan setting JAVA_HOME atau JAVA_JRE plus PATH nya baru kemudian saya startup.BAT.<br />
memang kita bisa menambahkan pada enviromental variables, jadi tidak perlu melakukan hal tersebut. tapi tetap saja saya harus melakukan startup dan shutdown melalui cmd.<br />
<br />
nah ini cara untuk membuatnya menjadi services windows dimana jika kita startup maka tak perlu lagi kita melakukan startup secara manual.<br />
<br />
caranya adalah dengan menggunakan perintah sederhana pada cmd :<br />
<ol style="text-align: left;"><li>masuk ke dalam direktori apache anda</li>
<li>kemudian ketikkan berikut<br />
bin\services.BAT install</li>
</ol>selesai dah..<br />
semoga bisa membantu.<br />
<br />
selanjutnya sebagai referensi bisa dilihat <a href="http://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html">di sini</a><br />
<br />
<br />
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-37184957674283663422011-01-28T07:12:00.000-08:002011-01-28T07:12:28.188-08:00Servlet Life Cyclepenting bagi kita memahami sebuah servlet life cycle guna memperdalam ilmu kita didalam JSP.<br />
jadi bagaimana inisialisasi sebuah servlet class ? hal itu dilakukan oleh sebuah Web Container. dimana hal2 yang dilakukan adalah sebagai berikut :<br />
<bold>1. Meload class Servlet</bold><br />
<bold>2. mencreate instance dari class Servlet</bold><br />
<bold>3. menginisialisasi instance dari class Servlet dengan menggunakan Init method</bold><br />
<bold>4. menginvoke service method untuk melakukan request and response prosedure</bold><br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoFFvQU7Slxl4CftaJAaSLGVS8HV1JJowL7fdrJ25dHV8q1qW55lCxlO9P9oWJ4NJgBEC_dnwdRqYTuV85kyoa0hFDIKflhDeie2rw0VjePfgc70o6k8dx8-xK4dz4P99TH8p4D0fa7hU/s1600/LifeCycle.gif" imageanchor="1" style="margin-left:1em; margin-right:1em"><img border="0" height="281" width="320" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoFFvQU7Slxl4CftaJAaSLGVS8HV1JJowL7fdrJ25dHV8q1qW55lCxlO9P9oWJ4NJgBEC_dnwdRqYTuV85kyoa0hFDIKflhDeie2rw0VjePfgc70o6k8dx8-xK4dz4P99TH8p4D0fa7hU/s320/LifeCycle.gif" /></a></div><br />
<br />
<br />
mudahnya saya buat sebuah class tuk demo sebuah life cycle dari servlet. semoga bisa memahami nya :)<br />
<blockquote>import java.io.IOException;<br />
<br />
import javax.servlet.ServletConfig;<br />
import javax.servlet.ServletException;<br />
import javax.servlet.http.HttpServlet;<br />
import javax.servlet.http.HttpServletRequest;<br />
import javax.servlet.http.HttpServletResponse;<br />
<br />
public class ServletLifeCycleExample extends HttpServlet {<br />
<br />
private int count;<br />
<br />
@Override<br />
public void init(ServletConfig config) throws ServletException {<br />
super.init(config);<br />
getServletContext().log("init() called");<br />
count=0;<br />
}<br />
<br />
@Override<br />
protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {<br />
getServletContext().log("service() called");<br />
count++;<br />
response.getWriter().write("Incrementig the count: Count = "+count);<br />
<br />
}<br />
<br />
@Override<br />
public void destroy() {<br />
getServletContext().log("destroy() called");<br />
} <br />
<br />
}</blockquote>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-39070946118795417192011-01-28T05:44:00.000-08:002011-01-28T07:14:04.848-08:00Install Manual Tomcat 7.0<div dir="ltr" style="text-align: left;" trbidi="on">Tomcat 7.0 adalah sebuah CGI server yang bersifat o pen source. kalian bisa mendapatkan Tomcat secara gratis melalui <a href="http://tomcat.apache.org/download-70.cgi">link ini </a>masuk ke binary distributions - Core dan download sesuai kebutuhan. karena di tutorial ini saya menggunakan operating system windows. maka saya mendownload .zip<br />
<br />
setelah download selesai maka unzip lah file tersebut. dan letakkan di directory sistem anda. (eg: C:\)<br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjdcyJyCWilHjBZvSQp3JFPtf0C60RIq5xpf5AI5f-qTCMdefMHiYBKiYOo2Ux3x5mQIeceppu3GpKNNQ1XMmizN3tqJQWl9R7FBiLTqCVDoBhmsnpfpUuz9a9CxsQasIppvhW8XBwrk8A/s1600/1.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="284" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjdcyJyCWilHjBZvSQp3JFPtf0C60RIq5xpf5AI5f-qTCMdefMHiYBKiYOo2Ux3x5mQIeceppu3GpKNNQ1XMmizN3tqJQWl9R7FBiLTqCVDoBhmsnpfpUuz9a9CxsQasIppvhW8XBwrk8A/s320/1.JPG" width="320" /></a></div>diatas adalah struktur dari directory tomcat.<br />
sekarang kita akan mencoba untuk melakukan start manual server tomcat 7.0<br />
untuk itu kita perlu mendaftarkan enviromental variabels java ke directory tomcat untuk dapat dikenali.<br />
caranya adalah seperti berikut ini :<br />
<ol style="text-align: left;"><li>windows+run : ketikkan cmd lalu muncul lah command console.</li>
<li>pindah ke directory tomcay7.0 menggunakan cd (perintah berpindah current directory)</li>
<li>kemudian daftarkan variabel java menggunakan <br />
set JAVA_HOME=<directory jdk berada></li>
<li>set juga Classpath nya<br />
set PATH=%JAVA_HOME%\bin;%PATH% </li>
<li>kemudian berpindahlah ke directory bin dan jalankan startup.BAT menggunakan code berikut<br />
bin\startup</li>
<li>setelah itu. test menggunakan browser dengan mengetikkan <br />
http://localhost:8080/<br />
<8080 adalah port default yang digunakan oleh Tomcat></li>
</ol>berikut gambar lengkap code command nya :<br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEigt7qv2sJYDoB5wIFDEuyE693HVeprWi5q34H-B8HHor1IZBxrUIT-T0JN8Gc1hJQKjXoYbxn6KNa-E34VdnoZ7WQcOMQefViu_zxsB1Fb1jVQC6hXywHULMouvw_wOQQJmf_v6MD2n9E/s1600/2.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="120" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEigt7qv2sJYDoB5wIFDEuyE693HVeprWi5q34H-B8HHor1IZBxrUIT-T0JN8Gc1hJQKjXoYbxn6KNa-E34VdnoZ7WQcOMQefViu_zxsB1Fb1jVQC6hXywHULMouvw_wOQQJmf_v6MD2n9E/s320/2.JPG" width="320" /></a></div><br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhUGN3iN-noZ9ZJ2qSl4Wz_z28WBKlphB1D14r-pXbK1Xfwk6VfOw69TWT9KYzsnKNwUBu1YlQQBWWXEUK497aT1DypviMagGYVDIy9G0qWEcCUAAWl0VV5t6HWxf9HJScnE1XRhjeJf0o/s1600/2.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="187" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhUGN3iN-noZ9ZJ2qSl4Wz_z28WBKlphB1D14r-pXbK1Xfwk6VfOw69TWT9KYzsnKNwUBu1YlQQBWWXEUK497aT1DypviMagGYVDIy9G0qWEcCUAAWl0VV5t6HWxf9HJScnE1XRhjeJf0o/s320/2.JPG" width="320" /></a></div><br />
<br />
</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com0tag:blogger.com,1999:blog-4467336557173928576.post-45055979287551508492011-01-26T09:05:00.001-08:002011-01-26T09:05:49.110-08:00H-1 KP Pertamina Jakarta<div dir="ltr" style="text-align: left;" trbidi="on">Besok berangkt KP.<br />
semua persiapan sudah siap. tinggal nemuin pembimbing KP Bpk. Arif Basofi.<br />
<br />
semoga semua lancar kawan.<br />
<br />
anyway ini first post pertama di blog ini. mohon bantuan nya yak !!</div>Anonymoushttp://www.blogger.com/profile/16460974702704921260noreply@blogger.com4