Sasa Posted January 28, 2008 Report Share Posted January 28, 2008 Kā lai norāda ceļu līdz datubāzei, ja es gribu, lai tā atrastos tur pat kur visi pārējie web'am vajadzīgie faili! kad mēģinu šādi: strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=Katalogs.mdb" tad viņš man to db meklē uz desktopa, bet visi faili man ir iekš c:\web_katalogs\ šeit: strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\\192.168.0.150\tmp\webk\Katalogs.mdb" db atrodas pavisam uz cita datora ne tur kur visi faili un šādi pieslēgies sanāk, bet es negribu lai db atrodas visu laiku vien viet un es nevaru tik brīvi pārvietot to db failu, jo tad man nāksies pārrakstīt visas konekcijas uz db iekš visiem failiem! Link to comment Share on other sites More sharing options...
Aleksejs Posted January 28, 2008 Report Share Posted January 28, 2008 strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\web_katalogs\Katalogs.mdb" Link to comment Share on other sites More sharing options...
Sasa Posted January 28, 2008 Author Report Share Posted January 28, 2008 a savādāka varinata nav? piemēram IMG tagā neraksta visu pilno ceļu līdz failam un tad html's skatās tanī pašā mapē kur viņš pats atrodās. Nevar arī kaut kā līdzīgi ar DB failu izdarīties? Link to comment Share on other sites More sharing options...
Aleksejs Posted January 28, 2008 Report Share Posted January 28, 2008 strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=./Katalogs.mdb" Link to comment Share on other sites More sharing options...
Sasa Posted January 28, 2008 Author Report Share Posted January 28, 2008 šajā variantā arī uz desktopa tiek meklēta db! Link to comment Share on other sites More sharing options...
bubu Posted January 28, 2008 Report Share Posted January 28, 2008 Lai arī šite rakstīts par SQL serveri, bet ideja ir tāda pati kā accesam: http://www.codeprof.com/dev-archive/139/12-45-1393070.shtm Relative paths will not work in this scenario. The problem is you don't know the context of where the linked server code runs. Link to comment Share on other sites More sharing options...
Recommended Posts