Jump to content

Archived

This topic is now archived and is closed to further replies.

chernyshevsky

New OLE-DB extension for connecting to MS SQL

Recommended Posts

Hi, this is great. The only problem i have is that i don't seem to be able to update AD. I can run SELECT queries fine. Is this right or should i be able to update records in AD?

Thanks

Share this post


Link to post
Share on other sites
[quote author=meloks link=topic=106192.msg452516#msg452516 date=1160996048]
Do you know if you can force OLE DB do endoding conversion from UCS-2 (MS SQL) to UTF-8 (on web page)?

Regards.
[/quote]

The extension does conversion to UTF-8. See the readme file.

Share this post


Link to post
Share on other sites
[quote author=a_sheldon link=topic=106192.msg452597#msg452597 date=1161006977]
Hi, this is great. The only problem i have is that i don't seem to be able to update AD. I can run SELECT queries fine. Is this right or should i be able to update records in AD?

Thanks
[/quote]

The AD OLE-DB provider only provides read-only access, unfortunately.

Share this post


Link to post
Share on other sites
Hey, Cherny.  I took a while off on my project and I'm back working on it now.

I hit a strange error on one of my assoc fetches.  I really can't figure out what is going on with the code as it is basically a copy of code that works elsewhere.  Here is the error in hopes you can tell me what it means from an OLE point of view so I can fix my code.

Warning: oledb_fetch_assoc() [function.oledb-fetch-assoc]: Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done in C:\wamp\www\artist.php on line 168

Thanks mate!

Edit: Code blocks made it hard to read.

Share this post


Link to post
Share on other sites
Ok, found some hinting of varchar length issues on google and sure enough, I had the varchar length set to MAX in the DB.  I changed it to a fixed length of 8000 and it started working like a champ again.

Just FYI and sorry to bother you all.

Share this post


Link to post
Share on other sites
Hey Cherny,

I'm getting some weird behaviour on one of my updates.  I'm binding a variable using OLEDB_TEXT and sending it to a large varchar (2000 or so) and it is having weird issues at 256 chars.  I remember reading somewhere about problems with varchars out to 256 characters and I think I was having this problem before you hinted moving to OLEDB_TEXT.  Well, I just noticed that didn't really solve the problem.  The text length saved is the same as the text I attempted to insert, but it starts to repeat from the beginning and goes on until it is as long as the entered text.

For example:

[quote]"Abra Moore (born June 8, 1969 in San Diego, California) is a folk-styled alternative rock singer-songwriter. She is an icon of the Austin, Texas music scene. Her 1997 album Strangest Places spun off the hit "Four Leaf Clover", which saw airplay in Midwest U.S. radio markets and VH1 and MTV2 rotation. Moore's parents named Abra after the heroine of John Steinbeck's East of Eden. She was raised in Puna, Hawaii in a bohemian household that had very strong jazz influences, including jam sessions by guest musicians. When she was 19 she founded Poi Dog Pondering with a group of friends, moving to Los Angeles in 1988 and to Austin in 1992. Moore left the band shortly afterward to pursue a solo career. Her first album was Sing (1995), followed by Strangest Places (1997), which had a companion CD "Live from the Strangest Places", featuring acoustic versions of several tracks from the album.

Abra continued to work on her next studio album "No Fear", while contributing songs to several soundtracks. Amidst rumors of creative differences and contractual conflicts, she changed management and recording companies and the album was eventually shelved, although her record label, J Records, did release promo copies. Most of the songs later appeared in slightly altered versions on her latest album, "Everything Changed" (2004) released on Koch Records."[/quote]

When inserted using OLEDB_TEXT produces:

[quote]Abra Moore (born June 8, 1969 in San Diego, California) is a folk-styled alternative rock singer-songwriter. She is an icon of the Austin, Texas music scene. Her 1997 album Strangest Places spun off the hit "Four Leaf Clover", which saw airplay in Midwest U.S. radio markets and VH1 and MTV2 rotation. Moore's parents named Abra after the heroine of John Steinbeck's East of Eden. She was raised in Puna, Hawaii in a bohemian household that had very strong jazz influences, including jam sessions by guest musicians. When she was 19 she founded Poi Dog Pondering with a group of friends, moving to Los Angeles in 1988 and to Austin in 1992. Moore left the band shortly afterward to pursue a solo career. Her first album was Sing (1995), followed by Strangest Places (1997), which had a companion CD "Live from the Strangest Places", featuring acoustic versions of several tracks from the album.

Abra continued to work on her next studio album "No Fear", while contributing songs to several soundtracks. Amidst rumAbra Moore (born June 8, 1969 in San Diego, California) is a folk-styled alternative rock singer-songwriter. She is an icon of the Austin, Texas music scene. Her 1997 album Strangest Places spun off the hit "Four Leaf Clover", which saw airplay in Midwest U.S. radio markets and VH1 and MTV2 rotation. Moore's parents named Abra after the[/quote]

Really weird...

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.