Loading...
 
Architecture / Installation

Architecture / Installation


MSSQL

posts: 8

I'm trying to get tikiwiki to work with microsoft sql server 2000.
If i use the adodb sybase i can't authenticate with the sql server.
If i use mssql i can authenticate. I replace all the sybase with mssql in.
tikidblib.php
tiki-setup.php
tiki-install.php.

But i can't get it to work yet. Who can help me.

I really like to use the mssql database

posts: 8

Warning: mssql error: Line 1: Incorrect syntax near '='. in query:
select "userId" from "users_users" where "login"=?
in D:\tk_t\tikiwiki-1.8\lib\tikidblib.php on line 125
Values:
Array ( 0 => )
$result is false
$result is empty


posts: 2881 United Kingdom

Hi calvan,

Ive been trying the same myself.
Sybase doesnt work you have to use mssql

Its going to need a little hard graft. From what I can work out, I added the mssql, but the SQL needs formatting

The ` needs eliminating
The ? needs wrapping with "?"
and the fields need wrapping with [field]

I'm working on it, but its a headache.

Ive been working on the function convert_query in tikidblib too.

But at the moment, Im at the same stage with exactly the same message as you.

btw. I got the installer to run ok :-)

posts: 31 United Kingdom

Hi there!

What's the current status with the MSSQL work? I've just downloaded TikiWiki 1.9 RC3, and I'm about to install it with IIS and MSSQL. Is there anything I should be aware of?

Ta,
Rikrak

posts: 2881 United Kingdom

Yeah it wont work. the .sql file for mssql is missing.

I need to re-create the convert script to re-generate that file.

Should be done by the time 1.9 is actually released.

Damian

posts: 1 Canada

I went through the process of building an MS SQL script from the sybase script (manually - and somewhat hacked - not knowing exactly what every table was for). I got it to install, and even run for the basics.

It took a bunch of minor code changes (including getting the latest version of the php adodb drivers). It also involved some minor changes to the convert_query function as mentioned by Damian (and a couple of other places as well).

I have this code (as mods to the 1.9 RC2 line), but again, I would consider it a hack, since I didn't really know where I was going.

At the end of it all though, there are still lots of issues running with MS SQL (which made it a non-starter for me - too dangerous since I had done the easy global fixes, and now little diffuclt problems were popping up here and there). Some of the problems escape me now, but they included:
- MSSQL has image and text columns, in MySQL its all the same
- tiki simply binds image data as string bind vars in the sql, and MSSQL does not support this for images. You either have to use a special function to bind binary data or you have to send the data as ascii-coded binary. I changed the adodb code to search for nulls in the string, and if found, bin2hex the data
- issues with UNICODE and the way null insertions were interpreted by MSSQL (I switched the DB library for MSSQL to bind as ASCII instead of UNICODE)
- I have troubles with array-merge calls in the tracker feature (not sure what this relates to, but is maybe how data is returned from MSSQL)
- a number of important columns are of type image (or text), but are used in where clauses and MSSQL does not support = comparisons (must use like)
- tiki inserts id=0 into identity columns (to indicate auto-increment) - does not work with MSSQL
- other null related issues that could be related to my own SQL script for the DB (I changed a lot of '' defaults to null and allowed nulls)

So those are my 2 cents. I would be happy to contribute my changes, but I'm not sure they are correct or do anyone any good.

send me a message on tiki if you are interested.

najb


posts: 31 United Kingdom

Sounds like a lot of work to do, with some uncertainty left over. In which case, I may scout around for an old box, install AMP, and prototype from that.

Thanks for the input, fellas.

RikRak.

PS Probably won't make the TikiFest this time, but thanks for the invite!


posts: 8

my installer doesn't work. i do it manual.
run the script with the query analyzer

posts: 2881 United Kingdom

> calvin:
> my installer doesn't work. i do it manual.
> run the script with the query analyzer

Ok, well I have a working installer wink
I thought that by getting that to run would be a great step into attacking tiki but there it stops sad

Damian


posts: 2881 United Kingdom

> calvin:
> my installer doesn't work. i do it manual.
> run the script with the query analyzer

Ok, well I have a working installer wink
I thought that by getting that to run would be a great step into attacking tiki but there it stops sad

Damian


posts: 8

I new the php.
I always used asp/asp .net/vb/vb .net blabla.

So i have to get used to php the get this working maybe i'll ask a fried of my. My problem is i can't find where the query gets called.

The select "userId" from "users_users" where "login"=?
because the array is allso empty.


posts: 1

Hey Guys,
I need to install TikiWiki on my WebServer and I need to use MSSQL aswell. I tried to do it and didnt have much luck. I have a windows IIS server, and I followed the IIS installation instructions (I skipped the MySQL part). It's seems like TikiWiki cannot detect any other databases other than MySQL.


posts: 31 United Kingdom

Hi there!

What's the current status with the MSSQL work? I've just downloaded TikiWiki 1.9 RC3, and I'm about to install it with IIS and MSSQL. Is there anything I should be aware of?

Ta,
Rikrak

posts: 2881 United Kingdom

Yeah it wont work. the .sql file for mssql is missing.

I need to re-create the convert script to re-generate that file.

Should be done by the time 1.9 is actually released.

Damian

posts: 1 Canada

I went through the process of building an MS SQL script from the sybase script (manually - and somewhat hacked - not knowing exactly what every table was for). I got it to install, and even run for the basics.

It took a bunch of minor code changes (including getting the latest version of the php adodb drivers). It also involved some minor changes to the convert_query function as mentioned by Damian (and a couple of other places as well).

I have this code (as mods to the 1.9 RC2 line), but again, I would consider it a hack, since I didn't really know where I was going.

At the end of it all though, there are still lots of issues running with MS SQL (which made it a non-starter for me - too dangerous since I had done the easy global fixes, and now little diffuclt problems were popping up here and there). Some of the problems escape me now, but they included:
- MSSQL has image and text columns, in MySQL its all the same
- tiki simply binds image data as string bind vars in the sql, and MSSQL does not support this for images. You either have to use a special function to bind binary data or you have to send the data as ascii-coded binary. I changed the adodb code to search for nulls in the string, and if found, bin2hex the data
- issues with UNICODE and the way null insertions were interpreted by MSSQL (I switched the DB library for MSSQL to bind as ASCII instead of UNICODE)
- I have troubles with array-merge calls in the tracker feature (not sure what this relates to, but is maybe how data is returned from MSSQL)
- a number of important columns are of type image (or text), but are used in where clauses and MSSQL does not support = comparisons (must use like)
- tiki inserts id=0 into identity columns (to indicate auto-increment) - does not work with MSSQL
- other null related issues that could be related to my own SQL script for the DB (I changed a lot of '' defaults to null and allowed nulls)

So those are my 2 cents. I would be happy to contribute my changes, but I'm not sure they are correct or do anyone any good.

send me a message on tiki if you are interested.

najb


posts: 31 United Kingdom

Sounds like a lot of work to do, with some uncertainty left over. In which case, I may scout around for an old box, install AMP, and prototype from that.

Thanks for the input, fellas.

RikRak.

PS Probably won't make the TikiFest this time, but thanks for the invite!


Upcoming Events

1)  18 Apr 2024 14:00 GMT-0000
Tiki Roundtable Meeting
2)  16 May 2024 14:00 GMT-0000
Tiki Roundtable Meeting
3)  20 Jun 2024 14:00 GMT-0000
Tiki Roundtable Meeting
4)  18 Jul 2024 14:00 GMT-0000
Tiki Roundtable Meeting
5)  15 Aug 2024 14:00 GMT-0000
Tiki Roundtable Meeting
6)  19 Sep 2024 14:00 GMT-0000
Tiki Roundtable Meeting
7) 
Tiki birthday
8)  17 Oct 2024 14:00 GMT-0000
Tiki Roundtable Meeting
9)  21 Nov 2024 14:00 GMT-0000
Tiki Roundtable Meeting
10)  19 Dec 2024 14:00 GMT-0000
Tiki Roundtable Meeting