Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #64123 > unrolled thread

Process datafeed in one MySql table and output to another MySql table

Started bySam <lightaiyee@gmail.com>
First post2014-01-16 17:03 -0800
Last post2014-01-16 19:23 -0700
Articles 5 — 4 participants

Back to article view | Back to comp.lang.python


Contents

  Process datafeed in one MySql table and output to another MySql table Sam <lightaiyee@gmail.com> - 2014-01-16 17:03 -0800
    Re: Process datafeed in one MySql table and output to another MySql table Denis McMahon <denismfmcmahon@gmail.com> - 2014-01-17 02:07 +0000
      Re: Process datafeed in one MySql table and output to another MySql table Sam <lightaiyee@gmail.com> - 2014-01-17 00:53 -0800
        Re: Process datafeed in one MySql table and output to another MySql table Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-01-17 09:23 +0000
    Re: Process datafeed in one MySql table and output to another MySql table Jason Friedman <jsf80238@gmail.com> - 2014-01-16 19:23 -0700

#64123 — Process datafeed in one MySql table and output to another MySql table

FromSam <lightaiyee@gmail.com>
Date2014-01-16 17:03 -0800
SubjectProcess datafeed in one MySql table and output to another MySql table
Message-ID<e78e38ba-ce13-49ec-b988-11002f22124d@googlegroups.com>
I have a datafeed which is constantly sent to a MySql table. The table grows constantly as the data feeds in. I would like to write a python script which process the data in this table and output the processed data to another table in another MySql database in real-time.

Which are the python libraries which are suitable for this purpose? Are there any useful sample code or project on the web that I can use as reference? Thank you.

[toc] | [next] | [standalone]


#64132

FromDenis McMahon <denismfmcmahon@gmail.com>
Date2014-01-17 02:07 +0000
Message-ID<lba39u$7p1$6@dont-email.me>
In reply to#64123
On Thu, 16 Jan 2014 17:03:24 -0800, Sam wrote:

> I have a datafeed which is constantly sent to a MySql table ...

> Which are the python libraries which are suitable for this purpose? Are
> there any useful sample code or project on the web that I can use as
> reference?

Did you search for mysql on the python docs website, or perhaps try 
googling "python mysql"?

-- 
Denis McMahon, denismfmcmahon@gmail.com

[toc] | [prev] | [next] | [standalone]


#64145

FromSam <lightaiyee@gmail.com>
Date2014-01-17 00:53 -0800
Message-ID<6dacfcba-e677-4c62-878e-c14c70d6b654@googlegroups.com>
In reply to#64132
On Friday, January 17, 2014 10:07:58 AM UTC+8, Denis McMahon wrote:
> On Thu, 16 Jan 2014 17:03:24 -0800, Sam wrote:
> 
> 
> 
> > I have a datafeed which is constantly sent to a MySql table ...
> 
> 
> 
> > Which are the python libraries which are suitable for this purpose? Are
> 
> > there any useful sample code or project on the web that I can use as
> 
> > reference?
> 
> 
> 
> Did you search for mysql on the python docs website, or perhaps try 
> 
> googling "python mysql"?
> 

I did. There were documentation but I was hoping to have more sample code. Preferably a similar project which I can use as reference.

> 
> 
> -- 
> 
> Denis McMahon, denismfmcmahon@gmail.com

[toc] | [prev] | [next] | [standalone]


#64149

FromMark Lawrence <breamoreboy@yahoo.co.uk>
Date2014-01-17 09:23 +0000
Message-ID<mailman.5629.1389950705.18130.python-list@python.org>
In reply to#64145
On 17/01/2014 08:53, Sam wrote:
> On Friday, January 17, 2014 10:07:58 AM UTC+8, Denis McMahon wrote:
>> On Thu, 16 Jan 2014 17:03:24 -0800, Sam wrote:
>>
>>
>>
>>> I have a datafeed which is constantly sent to a MySql table ...
>>
>>
>>
>>> Which are the python libraries which are suitable for this purpose? Are
>>
>>> there any useful sample code or project on the web that I can use as
>>
>>> reference?
>>
>>
>>
>> Did you search for mysql on the python docs website, or perhaps try
>>
>> googling "python mysql"?
>>
>
> I did. There were documentation but I was hoping to have more sample code. Preferably a similar project which I can use as reference.
>
>>
>>
>> --
>>
>> Denis McMahon, denismfmcmahon@gmail.com

Would you please read and action this 
https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the 
double line spacing above, thanks.

-- 
My fellow Pythonistas, ask not what our language can do for you, ask 
what you can do for our language.

Mark Lawrence

[toc] | [prev] | [next] | [standalone]


#64133

FromJason Friedman <jsf80238@gmail.com>
Date2014-01-16 19:23 -0700
Message-ID<mailman.5619.1389925394.18130.python-list@python.org>
In reply to#64123

[Multipart message — attachments visible in raw view] — view raw

>
> I have a datafeed which is constantly sent to a MySql table. The table
> grows constantly as the data feeds in. I would like to write a python
> script which process the data in this table and output the processed data
> to another table in another MySql database in real-time.
>
> Which are the python libraries which are suitable for this purpose? Are
> there any useful sample code or project on the web that I can use as
> reference? Thank you.
>

Is there a reason you do not want to move these rows with a mysql command?
drop table if exists temp;
insert into temp select * from source where ...;
insert into target select * from temp;
delete from source where id in (select id from temp);

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web