LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Password
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.

Notices


Reply
  Search this Thread
Old 01-08-2009, 12:08 AM   #1
atmurali
Member
 
Registered: Nov 2007
Location: Kerala
Posts: 42

Rep: Reputation: 15
Linux C


Hello,
I want to write a C program in Linux Platform to update a database server. Is it technically possible to access a database server
using C- Programming?

Please Reply me
Anoob T Murali
 
Old 01-08-2009, 01:29 AM   #2
sparc86
Member
 
Registered: Jul 2006
Location: Joinville, Brazil
Distribution: Debian, CentOS
Posts: 301

Rep: Reputation: 31
Do you want to update a database server? What do you want to do exactly, updating data or updating the database itself?

In both cases, I can't see why would you need C programming.

But please give us more input.
 
Old 01-08-2009, 07:31 AM   #3
PEdroArthur_JEdi
LQ Newbie
 
Registered: Jan 2008
Distribution: Slackware | Debian
Posts: 17

Rep: Reputation: 1
Assuming that you want to update the data at the database, just look for C bindings for your database server. For MySQL C API, have a look at http://dev.mysql.com/doc/refman/5.1/en/c.html. Contact your vendor for further information.

By the way, you post on embedded systems session. Will this be used from a embedded device? Would you explain the purpose of it?
 
Old 01-08-2009, 11:30 PM   #4
atmurali
Member
 
Registered: Nov 2007
Location: Kerala
Posts: 42

Original Poster
Rep: Reputation: 15
C-data

Hello,
Actually I need to update a data in a database using C program in Linux platform. This is for an embedded device running a Linux OS. Since the memory is low we are thinking about C-Programming. Any c,c++ variants can be used. If you please, tell me the logic how a database accessing works?
 
Old 01-09-2009, 11:18 AM   #5
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,399
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
As someone already described, most database servers have C bindings to allow your application to access the database. In the two cases I have tried, the API allows you to compose SQL queries to manipulate the database in much the same way you would do it interactively with any other tool. You send queries as strings, and read the replies as strings, arrays, etc.
What DBMS are you using?

--- rod.
 
Old 01-21-2009, 11:06 AM   #6
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fedora-35
Posts: 5,313

Rep: Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918
i would assume the mysql client is written in c so of course re-implimenting another client to connect to a mysql database server is possible (i suppose other database servers should work as well). mysql can connect to other hosts on a network.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer

All times are GMT -5. The time now is 02:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration