Search Results

Search found 6630 results on 266 pages for 'cname record'.

Page 38/266 | < Previous Page | 34 35 36 37 38 39 40 41 42 43 44 45  | Next Page >

  • how can i make sure only a single record is inserted when multiple apache threads are trying to acce

    - by Ed Gl
    I have a web service (xmlrpc service to be exact) that handles among other things writing data into the database. Here's the scenario: I often receive requests to either update or insert a record. What I would do is this: If the record already exists, append to the record, If not, create a new record The issue is that there are certain times I would get a 'burst' of requests, which spawns several apache threads to handle the request. These 'bursts' would come within less than milliseconds of each other. I now have several threads performing #1 and #2. Often two threads would would 'pass' number #1 and actually create two duplicate records (except for the primary key). I'd like to use some locking mechanism to prevent other threads from accessing the table while the other thread finishes its work. I'm just afraid of using it because if something happens I don't want to leave the table locked. Is there a solid way of handling this? I'm open to using locks if I can do it properly. Thanks,

    Read the article

  • How do you play or record audio (to .WAV) on Linux in C++? [closed]

    - by Jacky Alcine
    Hello, I've been looking for a way to play and record audio on a Linux (preferably Ubuntu) system. I'm currently working on a front-end to a voice recognition toolkit that'll automate a few steps required to adapt a voice model for PocketSphinx and Julius. Suggestions of alternative means of audio input/output are welcome, as well as a fix to the bug shown below. Here is the current code I've used so far to play a .WAV file: void Engine::sayText ( const string OutputText ) { string audioUri = "temp.wav"; string requestUri = this->getRequestUri( OPENMARY_PROCESS , OutputText.c_str( ) ); int error , audioStream; pa_simple *pulseConnection; pa_sample_spec simpleSpecs; simpleSpecs.format = PA_SAMPLE_S16LE; simpleSpecs.rate = 44100; simpleSpecs.channels = 2; eprintf( E_MESSAGE , "Generating audio for '%s' from '%s'..." , OutputText.c_str( ) , requestUri.c_str( ) ); FILE* audio = this->getHttpFile( requestUri , audioUri ); fclose(audio); eprintf( E_MESSAGE , "Generated audio."); if ( ( audioStream = open( audioUri.c_str( ) , O_RDONLY ) ) < 0 ) { fprintf( stderr , __FILE__": open() failed: %s\n" , strerror( errno ) ); goto finish; } if ( dup2( audioStream , STDIN_FILENO ) < 0 ) { fprintf( stderr , __FILE__": dup2() failed: %s\n" , strerror( errno ) ); goto finish; } close( audioStream ); pulseConnection = pa_simple_new( NULL , "AudioPush" , PA_STREAM_PLAYBACK , NULL , "openMary C++" , &simpleSpecs , NULL , NULL , &error ); for (int i = 0;;i++ ) { const int bufferSize = 1024; uint8_t audioBuffer[bufferSize]; ssize_t r; eprintf( E_MESSAGE , "Buffering %d..",i); /* Read some data ... */ if ( ( r = read( STDIN_FILENO , audioBuffer , sizeof (audioBuffer ) ) ) <= 0 ) { if ( r == 0 ) /* EOF */ break; eprintf( E_ERROR , __FILE__": read() failed: %s\n" , strerror( errno ) ); if ( pulseConnection ) pa_simple_free( pulseConnection ); } /* ... and play it */ if ( pa_simple_write( pulseConnection , audioBuffer , ( size_t ) r , &error ) < 0 ) { fprintf( stderr , __FILE__": pa_simple_write() failed: %s\n" , pa_strerror( error ) ); if ( pulseConnection ) pa_simple_free( pulseConnection ); } usleep(2); } /* Make sure that every single sample was played */ if ( pa_simple_drain( pulseConnection , &error ) < 0 ) { fprintf( stderr , __FILE__": pa_simple_drain() failed: %s\n" , pa_strerror( error ) ); if ( pulseConnection ) pa_simple_free( pulseConnection ); } } NOTE: If you want the rest of the code to this file, you can download it here directly from Launchpad.

    Read the article

  • How to fix "Xlib: extension "RECORD" missing on display :1" in vnc session?

    - by Manish Sapariya
    I am running a JNativeHook capture program on Ubuntu. When I run the session on default X session things are working fine. However when I run the same program from vnc session, it fails with "Xlib: extension "RECORD" missing on display". I checked that this extension is loaded in X which is started by display manager/init. However I am not sure if indeed is initialized during vncserver startup. I could not see anything related in the vnc log. I tried create custom xorg.conf with Module section, which explicitly loads RECORD extension as suggested by many posts but did not help. My environment: Xorg-server: 2.1.12.4-6 tightvncserver: 1.3.9 The same thing works fine on my CentOS 6.4 setup.

    Read the article

  • What tool can record multiple parallel stream to files of defined size?

    - by Hauke
    I would like to record record multiple audio web streams like this one in parallel to an mp3 or wma file for a duration of several days. I would like to be able to limit the file size or the duration stored in each file. The tool can be for any operating system. I do not need anything fancy like song recognition, metadata or silence detection. I haven't been able to find such a piece of software so far. Example: Tap channel "News" results in: News-090902-0000-0100.mp3, News-090902-0100-0200.mp3, etc... Who knows what tool can do this? It can be commercial software. Link in fulltext: 88.84.145.116:8000/listen.pls

    Read the article

  • How to record my voice on a Mac Mini with headphones?

    - by user718408
    I'm try to record my voice via the headphone on a Mac Mini, but it's not working. I saw on Apple's site that the Mac Mini can record voice, but it doesn't seem to be working for me. Here is a hardware overview: Model Name: Mac Mini Model Identifier: Macmini3,1 Processor Name: Intel Core 2 Duo Processor Speed: 2.26 GHz Number Of Processors: 1 Total Number Of Cores: 2 L2 Cache: 3 MB Memory: 4 GB Audio: Make: Intel High Definition Audio Audio ID: 65 Headphone connection: Combination Output Line Input connection: Combination Input Speaker connection: Internal S/PDIF Optical Digital Audio Output connection: Combination Output S/PDIF Optical Digital Audio Input connection: Combination Input Any ideas how I can successfully get recording working?

    Read the article

  • Pointing a subdomain to Github Pages

    - by ratage
    I set up an Octopress blog on Github Pages at myusername.github.com. I now want blog.myusername.me (which currently has a Wordpress blog set up) to point to this Octopress blog. So I followed the instructions here on setting up a custom domain: I ran echo 'blog.myusername.me' >> source/CNAME in my Octopress repository, and then ran rake generate and rake deploy to deploy it to Github. I went to Namecheap, and added a new CNAME under my myusername.me domain: "blog - myusername.github.com - CNAME". Waited a couple hours. However, now when I go to myusername.github.com, it redirects me to blog.myusername.me (which is my old Wordpress blog), which seems like the inverse of what I want. (Going to blog.myusername.me directly still shows my Wordpress blog.) I checked http://www.whatsmydns.net/#CNAME/blog.myusername.me and it seems like my DNS has propagated (myusername.github.com shows up in the right-hand side). Any ideas what I'm doing wrong?

    Read the article

  • How to record desktop session with sound on Moblin?

    - by Moblin Newbie
    I have tried to record my desktop session with sound on a netbook running Moblin, but I can't seem to be able to record sound. xvidcap just says error accessing /dev/dsp. Are there some options I should pass to xvidcap? Should I use some other recording application? Update: I am using the latest xvidcap (1.1.7) and have read the FAQ. Unfortunately Moblin' gnome-volume-control looks nothing like what is linked to from the xvidcap FAQ; there is no way to to set or even look at the details the screenshot shows, as far as I know. alsamixer shows pulseaudio is used, if that gives anyone any clues. The device is Acer Aspire One.

    Read the article

  • How do I record sound from my CD/DVD player without other system sounds in the mix?

    - by Software Monkey
    Using GoldWave I can record via the "Stereo Mix" channel, but I get no sound on the "CD" channel. Of course, using the stereo mix also mixes in all system sounds, including beeps, etc. I have the analog out on the DVD player connected to the CD-IN connector on the MoBo. I can hear CDs and DVDs playing just fine through my speakers - is this because the CD is also IDE data connection in to deliver the sound to the sound card, then? I specifically want to record a DVD; I can easily rip a CD using GoldWave's built-in ripper. Is there anything I have forgotten or have to enable? Or is it likely I have a damaged cable? My system is an MSI mobo and is running Windows XP SP3.

    Read the article

  • How to record audio in Windows Server 2008 Web SP2?

    - by Aurelio De Rosa
    I face into this problem and before ask here I've searched and read a lot of question but no-one seems to fit to my problem. I have a server running Windows Server 2008 Web with the SP2 and a headset attached to it using audio jack. The server has audio driver since I can listen audio. This OS does not came with the built-in audio record tool (the one I have in Windows 7). I can access physically and remotely (using RDC) to this server with administration permission. My local pc has Windows 7 if it can help. All I want to do is to know if it's possible and how to record audio form the microphone (of the server) and store that file in the server from remote connection. I tried to install several software on the server but everyone fails with a different issues (missing DLL which if I put in the system the error doesn't go away).

    Read the article

  • How do I get Linq-to-SQL to refresh its local copy of a database record?

    - by Gary McGill
    Suppose I have an Orders table in my database and a corresponding model class generated by the VS2008 "Linq to SQL Classes" designer. Suppose I also have a stored procedure (ProcessOrder) in my database that I use to do some processing on an order record. If I do the following: var order = dataContext.Orders.Where(o => o.id == orderId).First(); // More code here dataContext.ProcessOrder(orderId); order.Status = "PROCESSED"; dataContext.SubmitChanges(); ...then I'll get a concurrency violation if the ProcessOrder stored proc has modified the order (which is of course very likely), because L2S will detect that the order record has changed, and will fail to submit the changes to that order. That's all fairly logical, but what if I want to update the order record after calling the stored proc? How do I tell L2S to forget about its cached copy and refresh it from the DB?

    Read the article

  • how to get an SDP record for bluetooth service??

    - by user302798
    Hi I'm new to both winsock and bluetooth programming. I need to develop a bluetooth service to run on a pc. Looking at the MSDN library they say to use WSASetService(http://msdn.microsoft.com/en-us/library/aa362921%28VS.85%29.aspx) function to publish a service. The problem is that the WSAQUERYSET(http://msdn.microsoft.com/en-us/library/aa362920%28VS.85%29.aspx) structure, that has to be passed to WSASetService, needs a binary SDP record and i don't know how to get it. In the Windows embedded section of the MSDN library they describe a procedure to obtain an SDP record using Bthnscreate. I installed Windows CE 6 to use this tool but i can't find it in the install directory nor in the entire system. How can i get an SDP record? Thanks!

    Read the article

  • after running insert or update query, need the last inserted record and compare in vb.net sql server

    - by ereffe
    i have 2 queries in vb.net with an if clause - if x=0 then insert into table1 else update table1 both queries have 5 fields. now what i want to do is after this insert or update takes place, i need to look at this inserted/updated record and compare it with another table (table2). Especially for update, i have 5 fields in both tables. if any of the 5 fields dont match with table2, then i insert a new record in table 2 which is the updated record in table 1. how can i do this?

    Read the article

  • Specify sorting order for a GROUP BY query to retrieve oldest or newest record for each group

    - by Beau Simensen
    I need to get the most recent record for each device from an upgrade request log table. A device is unique based on a combination of its hardware ID and its MAC address. I have been attempting to do this with GROUP BY but I am not convinced this is safe since it looks like it may be simply returning the "top record" (whatever SQLite or MySQL thinks that is). I had hoped that this "top record" could be hinted at by way of ORDER BY but that does not seem to be having any impact as both of the following queries returns the same records for each device, just in opposite order: SELECT extHwId, mac, created FROM upgradeRequest GROUP BY extHwId, mac ORDER BY created DESC SELECT extHwId, mac, created FROM upgradeRequest GROUP BY extHwId, mac ORDER BY created ASC Is there another way to accomplish this? I've seen several somewhat related posts that have all involved sub selects. If possible, I would like to do this without subselects as I would like to learn how to do this without that.

    Read the article

  • Profile creation process stuck halfway Websphere

    - by ngubk
    I'm creating a cell profile on Linux Mint 12 , WAS 8.0 Network Deployment Trial. But using manageProfiles.sh or Profile Management Tool, I can not create any profile (cell, application ...). When I check the log file, the profile creation process is always stop halfway (does not show any error, just stuck there). The log is always like this <record> <date>2012-11-02T04:11:15</date> <millis>1351847475108</millis> <sequence>2985</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>replacing value for user.install.root (null) with (/opt/IBM/WebSphere/AppServer/profiles)</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475108</millis> <sequence>2986</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>replacing value for was.install.root (/opt/IBM/WebSphere/AppServer) with (/opt/IBM/WebSphere/AppServer)</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475108</millis> <sequence>2987</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>replacing value for was.repository.root (null) with (/opt/IBM/WebSphere/AppServer/profiles/config)</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475108</millis> <sequence>2988</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>replacing value for com.ibm.ws.scripting.wsadminprops (null) with (/opt/IBM/WebSphere/AppServer/profiles/properties/wsadmin.properties)</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475120</millis> <sequence>2989</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>Resetting listener available status to: false</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475121</millis> <sequence>2990</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>setting wsadmin requester timeouts</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475128</millis> <sequence>2991</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>wsadmin requester retry count = 240000, initialization retry count = 12000, shutdown retry count = 12000</message> </record> <record> <date>2012-11-02T04:11:15</date> <millis>1351847475128</millis> <sequence>2992</sequence> <logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger> <level>INFO</level> <class>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</class> <method>messageLogged</method> <thread>0</thread> <message>Checking for wsadmin listener initialization</message> </record>

    Read the article

  • Sql or VB for Access

    - by vijay
    I Have a table in Access as below SI Number Time 1.14172E+20 13:30:35 1244066650 18:58:48 1244066650 19:03:12 1244066650 19:05:50 01724656007_dsl 22:15:20 01724656007_dsl 22:18:00 01724656007_dsl 22:24:28 1141530407 10:27:49 1141530407 10:29:13 And require output in the same table is SI Number Time Diff 1.14172E+20 13:30:35 1244066650 18:58:48 1244066650 19:03:12 0:04:24 1244066650 19:05:50 0:02:38 01724656007_dsl 22:15:20 01724656007_dsl 22:18:00 0:02:40 01724656007_dsl 22:24:28 0:06:28 1141530407 10:27:49 1141530407 10:29:13 0:01:24 I require as if 1st record in SI Number column is equals to 2nd record than record 2 of time column -record 1 of time column in Diff column record 2 record 1 will remain blank Urgent help required Vijay

    Read the article

  • Updating Data through Objects

    - by Chacha102
    So, lets say I have a record: $record = new Record(); and lets say I assign some data to that record: $record->setName("SomeBobJoePerson"); How do I get that into the database. Do I..... A) Have the module do it. class Record{ public function __construct(DatabaseConnection $database) { $this->database = $database; } public function setName($name) { $this->database->query("query stuff here"); $this->name = $name; } } B) Run through the modules at the end of the script class Record{ private $changed = false; public function __construct(array $data=array()) { $this->data = $data; } public function setName($name) { $this->data['name'] = $name; $this->changed = true; } public function isChanged() { return $this->changed; } public function toArray() { return $this->array; } } class Updater { public function update(array $records) { foreach($records as $record) { if($record->isChanged()) { $this->updateRecord($record->toArray()); } } } public function updateRecord(){ // updates stuff } }

    Read the article

  • How to eliminate duplicate nodes bases on values of multiple attributes?

    - by JayRaj
    Hello All, How can I eliminate duplicate nodes based on values of multiple (more than 1) attributes? Also the attribute names are passed as parameters to the stylesheet. Now I am aware of the Muenchian method of grouping that uses a <xsl:key> element. But I came to know that XSLT 1.0 does not allow paramters/variables in <xsl:key>. Is there another method(s) to achieve duplicate nodes removal? It is fine if it not as efficient as the Munechian method. Update from previus question: XML: <data id = "root"> <record id="1" operator1='xxx' operator2='yyy' operator3='zzz'/> <record id="2" operator1='abc' operator2='yyy' operator3='zzz'/> <record id="3" operator1='abc' operator2='yyy' operator3='zzz'/> <record id="4" operator1='xxx' operator2='yyy' operator3='zzz'/> <record id="5" operator1='xxx' operator2='lkj' operator3='tyu'/> <record id="6" operator1='xxx' operator2='yyy' operator3='zzz'/> <record id="7" operator1='abc' operator2='yyy' operator3='zzz'/> <record id="8" operator1='abc' operator2='yyy' operator3='zzz'/> <record id="9" operator1='xxx' operator2='yyy' operator3='zzz'/> <record id="10" operator1='rrr' operator2='yyy' operator3='zzz'/> </data>

    Read the article

  • How to rewrite this eval block

    - by est
    Hi, This code smells... how do I rewrite it better? my $record; eval { while ( # undef $record here, so if getRecord() failed, nothing will be written # in the reject file do { undef $record; defined( $record = $dataFile->getRecord ) } ) { $LT_DataFile->encode($record); } 1; }; if ( my $error = $@ ) { $rejectFile->writeRecord( $error, $record ); } Thanks.

    Read the article

  • Optimization in Common Decalaration

    - by Pratik
    Its a 3-tier ASP.NET Website Project In Data Layer there is class "Common Decalaration" in which lot of common things are mentioned. Something this way : public class CommonDeclartion { #region Common Messages public const string RECORD_INSERT_MSG = "Record Inserted Successfully "; public const string RECORD_UPDATE_MSG = "Record Updated Successfully"; public const string RECORD_DELETE_MSG = "Record Deleted Successfully"; public const string ERROR_MSG = "Error Ocuured while Perfoming This Action."; public const string UserID_Incorrect = "Please Enter The Correct User ID."; public const string RECORD_ALREADY_EXIT = "Record Already Exit"; public const string NO_RECORD = "No Record found."; #endregion } Can this be more optimized in terms of : 1.Perfomance 2.Security(if any) 3.Code Readablity or Reusablity I thought of using enum but can't figure that out : enum CommonMessages { RECORD_INSERT_MSG "Record Inserted Successfully.", RECORD_UPDATE_MSG "Record Updated Successfully.", RECORD_DELETE_MSG "Record Deleted Successfully.", ERROR_MSG "Error Ocuured while Perfoming This Action.", UserID_Incorrect "Please Enter The Correct User ID.", RECORD_ALREADY_EXIT "Record Already Exit.", NO_RECORD "No Record found.", } or else should keep them in some collections like dictionary/NameValueCollection or so or i have to keep them in XML in form of key/value pair and reterive from it ? What can be better way keeping in mind 1.Perfomance 2.Security(if any) 3.Code Readablity or Reusablity

    Read the article

  • Sad logic on types

    - by user2972231
    Code base is littered with code like this: BaseRecord record = // some BaseRecord switch(record.source()) { case FOO: return process((FooRecord)record); case BAR: return process((BarRecord)record); case QUUX: return process((QuuxRecord)record); . . // ~25 more cases . } and then private SomeClass process(BarRecord record) { } private SomeClass process(FooRecord record) { } private SomeClass process(QuuxRecord record) { } It makes me terribly sad. Then, every time a new class is derived from BaseRecord, we have to chase all over our code base updating these case statements and adding new process methods. This kind of logic is repeated everywhere, I think too many to add a method for each and override in the classes. How can I improve this?

    Read the article

  • Creating a custom module for Orchard

    - by Moran Monovich
    I created a custom module using this guide from Orchard documentation, but for some reason I can't see the fields in the content type when I want to create a new one. this is my model: public class CustomerPartRecord : ContentPartRecord { public virtual string FirstName { get; set; } public virtual string LastName { get; set; } public virtual int PhoneNumber { get; set; } public virtual string Address { get; set; } public virtual string Profession { get; set; } public virtual string ProDescription { get; set; } public virtual int Hours { get; set; } } public class CustomerPart : ContentPart<CustomerPartRecord> { [Required(ErrorMessage="you must enter your first name")] [StringLength(200)] public string FirstName { get { return Record.FirstName; } set { Record.FirstName = value; } } [Required(ErrorMessage = "you must enter your last name")] [StringLength(200)] public string LastName { get { return Record.LastName; } set { Record.LastName = value; } } [Required(ErrorMessage = "you must enter your phone number")] [DataType(DataType.PhoneNumber)] public int PhoneNumber { get { return Record.PhoneNumber; } set { Record.PhoneNumber = value; } } [StringLength(200)] public string Address { get { return Record.Address; } set { Record.Address = value; } } [Required(ErrorMessage = "you must enter your profession")] [StringLength(200)] public string Profession { get { return Record.Profession; } set { Record.Profession = value; } } [StringLength(500)] public string ProDescription { get { return Record.ProDescription; } set { Record.ProDescription = value; } } [Required(ErrorMessage = "you must enter your hours")] public int Hours { get { return Record.Hours; } set { Record.Hours = value; } } } this is the Handler: class CustomerHandler : ContentHandler { public CustomerHandler(IRepository<CustomerPartRecord> repository) { Filters.Add(StorageFilter.For(repository)); } } the Driver: class CustomerDriver : ContentPartDriver<CustomerPart> { protected override DriverResult Display(CustomerPart part, string displayType, dynamic shapeHelper) { return ContentShape("Parts_Customer", () => shapeHelper.Parts_BankCustomer( FirstName: part.FirstName, LastName: part.LastName, PhoneNumber: part.PhoneNumber, Address: part.Address, Profession: part.Profession, ProDescription: part.ProDescription, Hours: part.Hours)); } //GET protected override DriverResult Editor(CustomerPart part, dynamic shapeHelper) { return ContentShape("Parts_Customer", () => shapeHelper.EditorTemplate( TemplateName:"Parts/Customer", Model: part, Prefix: Prefix)); } //POST protected override DriverResult Editor(CustomerPart part, IUpdateModel updater, dynamic shapeHelper) { updater.TryUpdateModel(part, Prefix, null, null); return Editor(part, shapeHelper); } the migration: public class Migrations : DataMigrationImpl { public int Create() { // Creating table CustomerPartRecord SchemaBuilder.CreateTable("CustomerPartRecord", table => table .ContentPartRecord() .Column("FirstName", DbType.String) .Column("LastName", DbType.String) .Column("PhoneNumber", DbType.Int32) .Column("Address", DbType.String) .Column("Profession", DbType.String) .Column("ProDescription", DbType.String) .Column("Hours", DbType.Int32) ); return 1; } public int UpdateFrom1() { ContentDefinitionManager.AlterPartDefinition("CustomerPart", builder => builder.Attachable()); return 2; } public int UpdateFrom2() { ContentDefinitionManager.AlterTypeDefinition("Customer", cfg => cfg .WithPart("CommonPart") .WithPart("RoutePart") .WithPart("BodyPart") .WithPart("CustomerPart") .WithPart("CommentsPart") .WithPart("TagsPart") .WithPart("LocalizationPart") .Creatable() .Indexed()); return 3; } } Can someone please tell me if I am missing something?

    Read the article

  • How to get readable classname and title from HWND handle? in WinApi c++

    - by Marko29
    I am using the following enumchild proc to get hwnd of each window, the problem is that i am unable to somehow detect any info from each hwnd so i can do what i want with the ones that are detected as the ones i need. For example, how could i get window class name and the title of each window in the enum bellow? I tried something like.. BOOL CALLBACK EnumChildProc(HWND hwnd, LPARAM lParam) { TCHAR className[MAX_PATH]; GetClassName(hwnd, cName, _countof(cName)); cout << cName; return TRUE; } It just returns the hexadec handle info and every single time it is same, shouldnt the GetClassName func change the cName into new handle each time? Also GetClassName function returns number of chars written to cName, i dont really see how this is useful to me? I need to get my cName in some readable format so i can do something like if(cName == TEXT("classnameiamlookingfor" && hwndtitle = TEXT("thetitlethatinterestsme") DOSOMETHINGWITHIT(); But all i get here is hexadec mess.

    Read the article

  • Rails multi level model security

    - by rballz
    I have the need to do the following in Rails to mirror a desktop application: a User and an Office 'owns' a record, if you don't own the record on a user or office level you're kicked into the public realm. user gets read,write,delete to the model record office gets read/write/delete to the model record other or public gets read/write/delete to the model record e.g. UserA owns a model record with read/write/delete OfficeA owns a model with read/write other/public gets read I was wondering if a plugin/gem existed to grant this functionality?

    Read the article

  • SPARC T3-1 Record Results Running JD Edwards EnterpriseOne Day in the Life Benchmark with Added Batch Component

    - by Brian
    Using Oracle's SPARC T3-1 server for the application tier and Oracle's SPARC Enterprise M3000 server for the database tier, a world record result was produced running the Oracle's JD Edwards EnterpriseOne applications Day in the Life benchmark run concurrently with a batch workload. The SPARC T3-1 server based result has 25% better performance than the IBM Power 750 POWER7 server even though the IBM result did not include running a batch component. The SPARC T3-1 server based result has 25% better space/performance than the IBM Power 750 POWER7 server as measured by the online component. The SPARC T3-1 server based result is 5x faster than the x86-based IBM x3650 M2 server system when executing the online component of the JD Edwards EnterpriseOne 9.0.1 Day in the Life benchmark. The IBM result did not include a batch component. The SPARC T3-1 server based result has 2.5x better space/performance than the x86-based IBM x3650 M2 server as measured by the online component. The combination of SPARC T3-1 and SPARC Enterprise M3000 servers delivered a Day in the Life benchmark result of 5000 online users with 0.875 seconds of average transaction response time running concurrently with 19 Universal Batch Engine (UBE) processes at 10 UBEs/minute. The solution exercises various JD Edwards EnterpriseOne applications while running Oracle WebLogic Server 11g Release 1 and Oracle Web Tier Utilities 11g HTTP server in Oracle Solaris Containers, together with the Oracle Database 11g Release 2. The SPARC T3-1 server showed that it could handle the additional workload of batch processing while maintaining the same number of online users for the JD Edwards EnterpriseOne Day in the Life benchmark. This was accomplished with minimal loss in response time. JD Edwards EnterpriseOne 9.0.1 takes advantage of the large number of compute threads available in the SPARC T3-1 server at the application tier and achieves excellent response times. The SPARC T3-1 server consolidates the application/web tier of the JD Edwards EnterpriseOne 9.0.1 application using Oracle Solaris Containers. Containers provide flexibility, easier maintenance and better CPU utilization of the server leaving processing capacity for additional growth. A number of Oracle advanced technology and features were used to obtain this result: Oracle Solaris 10, Oracle Solaris Containers, Oracle Java Hotspot Server VM, Oracle WebLogic Server 11g Release 1, Oracle Web Tier Utilities 11g, Oracle Database 11g Release 2, the SPARC T3 and SPARC64 VII+ based servers. This is the first published result running both online and batch workload concurrently on the JD Enterprise Application server. No published results are available from IBM running the online component together with a batch workload. The 9.0.1 version of the benchmark saw some minor performance improvements relative to 9.0. When comparing between 9.0.1 and 9.0 results, the reader should take this into account when the difference between results is small. Performance Landscape JD Edwards EnterpriseOne Day in the Life Benchmark Online with Batch Workload This is the first publication on the Day in the Life benchmark run concurrently with batch jobs. The batch workload was provided by Oracle's Universal Batch Engine. System RackUnits Online Users Resp Time (sec) BatchConcur(# of UBEs) BatchRate(UBEs/m) Version SPARC T3-1, 1xSPARC T3 (1.65 GHz), Solaris 10 M3000, 1xSPARC64 VII+ (2.86 GHz), Solaris 10 4 5000 0.88 19 10 9.0.1 Resp Time (sec) — Response time of online jobs reported in seconds Batch Concur (# of UBEs) — Batch concurrency presented in the number of UBEs Batch Rate (UBEs/m) — Batch transaction rate in UBEs/minute. JD Edwards EnterpriseOne Day in the Life Benchmark Online Workload Only These results are for the Day in the Life benchmark. They are run without any batch workload. System RackUnits Online Users ResponseTime (sec) Version SPARC T3-1, 1xSPARC T3 (1.65 GHz), Solaris 10 M3000, 1xSPARC64 VII (2.75 GHz), Solaris 10 4 5000 0.52 9.0.1 IBM Power 750, 1xPOWER7 (3.55 GHz), IBM i7.1 4 4000 0.61 9.0 IBM x3650M2, 2xIntel X5570 (2.93 GHz), OVM 2 1000 0.29 9.0 IBM result from http://www-03.ibm.com/systems/i/advantages/oracle/, IBM used WebSphere Configuration Summary Hardware Configuration: 1 x SPARC T3-1 server 1 x 1.65 GHz SPARC T3 128 GB memory 16 x 300 GB 10000 RPM SAS 1 x Sun Flash Accelerator F20 PCIe Card, 92 GB 1 x 10 GbE NIC 1 x SPARC Enterprise M3000 server 1 x 2.86 SPARC64 VII+ 64 GB memory 1 x 10 GbE NIC 2 x StorageTek 2540 + 2501 Software Configuration: JD Edwards EnterpriseOne 9.0.1 with Tools 8.98.3.3 Oracle Database 11g Release 2 Oracle 11g WebLogic server 11g Release 1 version 10.3.2 Oracle Web Tier Utilities 11g Oracle Solaris 10 9/10 Mercury LoadRunner 9.10 with Oracle Day in the Life kit for JD Edwards EnterpriseOne 9.0.1 Oracle’s Universal Batch Engine - Short UBEs and Long UBEs Benchmark Description JD Edwards EnterpriseOne is an integrated applications suite of Enterprise Resource Planning (ERP) software. Oracle offers 70 JD Edwards EnterpriseOne application modules to support a diverse set of business operations. Oracle's Day in the Life (DIL) kit is a suite of scripts that exercises most common transactions of JD Edwards EnterpriseOne applications, including business processes such as payroll, sales order, purchase order, work order, and other manufacturing processes, such as ship confirmation. These are labeled by industry acronyms such as SCM, CRM, HCM, SRM and FMS. The kit's scripts execute transactions typical of a mid-sized manufacturing company. The workload consists of online transactions and the UBE workload of 15 short and 4 long UBEs. LoadRunner runs the DIL workload, collects the user’s transactions response times and reports the key metric of Combined Weighted Average Transaction Response time. The UBE processes workload runs from the JD Enterprise Application server. Oracle's UBE processes come as three flavors: Short UBEs < 1 minute engage in Business Report and Summary Analysis, Mid UBEs > 1 minute create a large report of Account, Balance, and Full Address, Long UBEs > 2 minutes simulate Payroll, Sales Order, night only jobs. The UBE workload generates large numbers of PDF files reports and log files. The UBE Queues are categorized as the QBATCHD, a single threaded queue for large UBEs, and the QPROCESS queue for short UBEs run concurrently. One of the Oracle Solaris Containers ran 4 Long UBEs, while another Container ran 15 short UBEs concurrently. The mixed size UBEs ran concurrently from the SPARC T3-1 server with the 5000 online users driven by the LoadRunner. Oracle’s UBE process performance metric is Number of Maximum Concurrent UBE processes at transaction rate, UBEs/minute. Key Points and Best Practices Two JD Edwards EnterpriseOne Application Servers and two Oracle Fusion Middleware WebLogic Servers 11g R1 coupled with two Oracle Fusion Middleware 11g Web Tier HTTP Server instances on the SPARC T3-1 server were hosted in four separate Oracle Solaris Containers to demonstrate consolidation of multiple application and web servers. See Also SPARC T3-1 oracle.com SPARC Enterprise M3000 oracle.com Oracle Solaris oracle.com JD Edwards EnterpriseOne oracle.com Oracle Database 11g Release 2 Enterprise Edition oracle.com Disclosure Statement Copyright 2011, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. Results as of 6/27/2011.

    Read the article

  • Data Synchronization in mobile apps - multiple devices, multiple users

    - by ProgrammerNewbie
    I'm looking into building my first mobile app. One of the core features of the application is that multiple devices/users will have access to the same data -- and all of them will have CRUD rights. I believe the architecture should involve a central server where all the data is stored. The devices will use an API to interact with the server to perform its data operations (e.g. adding a record, editing a record, deleting a record). I imagine a scenario where synchronizing the data will become a problem. Assume the application should work when it is not connected to the Internet, and thus cannot communicate with this central server. So: User A is offline and edits record #100 User B is offline and edits record #100 User C is offline and deletes record #100 User C goes online (presumably, record #100 should get deleted on the server) User A and B goes online, but the records they edited no longer exist All sorts of scenarios similar to the above can come up. How is this generally handled? I plan to use MySQL, but am wondering if it's not appropriate for such a problem.

    Read the article

< Previous Page | 34 35 36 37 38 39 40 41 42 43 44 45  | Next Page >