World: r4wp
[Databases] group to discuss various database issues and drivers
older newer | first last |
GrahamC 17-Mar-2012 [25] | and did you try opendbx? |
BrianH 17-Mar-2012 [26x2] | Fortunately we can improve ChristianE's R3 driver. Since I use it a lot at work, I need to. I'm just waiting until I have the time to spare, which hasn't happened in several months. |
Haven't tried OpenDBX yet. Don't know how R3-like its REBOL API is. | |
GrahamC 17-Mar-2012 [28] | WIP |
BrianH 17-Mar-2012 [29x4] | ChristianE implements an R2-like API in an R3 port model, and it just feels alien, though it does allow me to have more portable code between R2 and R3. This helps when i have to have a script extract data in R2 because it needs to get text or numeric type data, but then close and call itself in R3 to parse that data. My %rebol.r is R2 and R3 compatible. |
I figured out a way to make an R3-like ODBC API, and have an R2-like API emulated when you try to use it in an R2-like way. But then I ran out of time, was assigned to other projects for a while. | |
Nowadays I mostly write SQL, sometimes calling that SQL using R3, or others call it with ASP.NET, PHP or Java (merger code collection). | |
OpenDBX: Where are the REBOL drivers? The link on their site doesn't work. | |
Endo 17-Mar-2012 [33] | http://www.compkarori.co.nz:8000/OpenDBX |
BrianH 17-Mar-2012 [34] | Darn, OpenDBX's support for MSSQL is worse than REBOL's :( |
Endo 17-Mar-2012 [35] | OLEDB vs. ODBC; from Microsoft: "You are strongly encouraged to use one of the native OLE DB Providers instead of the Microsoft Open Database Connectivity (ODBC) Provider. Native OLE DB Providers provide better application stability and performance." at least for it was for SQL Server. But as you said OLEDB is now obsolete.. |
BrianH 17-Mar-2012 [36] | Yup, that must be an old quote, from back when they were promoting OLE DB so your code would be non-portable. They don't do that anymore. Now their new ODBC stacks in Vista and 7 are better than OLE DB. |
GrahamC 17-Mar-2012 [37x2] | http://linuxnetworks.de/doc/index.php/OpenDBX/DBMS_Datatypes |
what is exactly defiicient? I never used sql server | |
Endo 17-Mar-2012 [39] | BrianH: yes, this is an old quote. OpenDBX's support for MSSQL is worse than REBOL's - it doesn't look that bad, just new datatypes are not supported like TIME, DATE. |
BrianH 17-Mar-2012 [40x5] | Not new, core types. There are types OpenDBX can't that I am required to support. |
can't -> can't handle | |
Like the nchar and nvarchar types. OpenDBX converts those types to ASCII, then R3 would need to convert them back to Unicode. | |
A lot of the OpenDBX references to SQL Server don't seem to take SQL Server 2008 into account, so it's at least 3 versions behind now. Comparable to R2 I guess. | |
It makes a lot more sense to have OpenDBX bindings for R2 though, since the lack of Unicode support won't matter there. | |
Kaj 18-Mar-2012 [45] | OpenDBX is not a full SQL interface to databases, but a database abstraction of its own. They're probably not interested in supporting other features |
Pekr 18-Mar-2012 [46] | There's another interesting product here - http://sqlrelay.sourceforge.net/ |
GrahamC 18-Mar-2012 [47] | If you knew C, then you could add the nchar, and nvchar support |
BrianH 18-Mar-2012 [48] | Knowing C, it would be better to add it to the ODBC API, at least for someone who already knows SQL. That way you can get wider database support, since most SQL database vendors support ODBC. Heck, even Microsoft is making a free unixodbc driver for MSSQL. |
GrahamC 18-Mar-2012 [49x5] | It isn't even clear how sqlrelay works |
it sets up a tcp listener but I can't find the documentation of their line protocol | |
and windows support is not ready yet | |
No Rebol suppport of course. | |
So, Brian, want to ping Carl and ask for the ODBC sources for R2? | |
Pekr 18-Mar-2012 [54] | Is Carl "pingable" though? :-) |
BrianH 18-Mar-2012 [55] | Not by me. And I use R3, almost never R2. |
GrahamC 18-Mar-2012 [56] | Carl maybe firewalled |
BrianH 18-Mar-2012 [57] | Wait, how would you update the R2 protocol? |
GrahamC 18-Mar-2012 [58x2] | make the changes, send back to Carl, he releases new version |
Wasn't Robert going to create a database driver for R3? | |
BrianH 18-Mar-2012 [60x2] | Ah. Well, I'd prefer to make the changes to the R3 version first, since we can use that right away. The internal code could be backported to the R2 version when Carl resurfaces. |
ChristianE's odbc driver for R3 is already a little more useful than the R2 one, but needs a bit of work. Being open source, we can do the work. | |
GrahamC 18-Mar-2012 [62x2] | Except so few of us use R3 |
But if we can leverage the work for red .... | |
BrianH 18-Mar-2012 [64] | Doc has (iirc) expressed an interest in adapting R3's port model to Red. |
GrahamC 18-Mar-2012 [65] | adapting or adopting? |
BrianH 18-Mar-2012 [66] | Adopting. So much better than R2's port model. |
GrahamC 18-Mar-2012 [67] | So, we can reuse R3 documentation :) |
BrianH 18-Mar-2012 [68x4] | Ha! R3's documentation for its port model is a bit lacking :( |
There may need to be some tweaks for Red's ports due to the different language model though. Don't know for sure yet. | |
What's missing in the R3 port documentation is best practices examples for different usage models. The port model is so flexible you can almost use it as a way to create user-defined data types, but we're missing complex examples of the most efficient way to use the model. That's another reason I wanted to make a real R3-like odbc:// scheme, to learn the model better. | |
Oh, found that announcement about the end of OLEDB: http://blogs.msdn.com/b/sqlnativeclient/archive/2011/08/29/microsoft-is-aligning-with-odbc-for-native-relational-data-access.aspx | |
GrahamC 18-Mar-2012 [72] | so reality forced MS to drop back to ODBC |
BrianH 18-Mar-2012 [73] | Yup. You should see what they have in store for SQL Server 2012. It can be run on a fully command line OS, managed remotely entirely through PowerShell scripting. And you can do PowerShell scripting of MS servers from Linux clients too, reportedly. |
Endo 18-Mar-2012 [74] | PowerShell is a powerful scripting lanugage, but it is a mess, I don't understand why they never think about simplicity. |
older newer | first last |