Thank you! To all my friends at American Express Publishing. (NYC)

I just wanted to take a moment of my time and express my gratitude in working with each of you. I have to say that I really learned a whole lot and hopefully I left each of you a little better off as well. (Clockwise from the left) Many thanks to: Shailen our department manager And Anika, who taught me how to really use the SCRUM process. (I will strive to duplicate your scrum management skills at my next job). Kolette, who is mostly responsible for getting me all mixed up with this motley crew in the first place. Chad leads by example, and although he doesn't know it, he is singularly responsible for switching my breakfast diet from McMuffins to oatmeal. (Me in the back right-hand side) Jorge, who taught me to lock my computer when I step away. David taught me that if you know when enough is enough...then you will always have enough! Gary helped launch my second career as a professional Foosball player. (I am still waiting for that agent to call me). Karthic (DBA extraordinaire!) taught me a million things about SQL Server most of which I never dreamed where possible. And last and most certainly least, Steve, who taught me that it is okay to eat bagels even if they are not made with NYC water. Thank you again!

www.crystaltech.com Sucks!

Ever since I purchased a shared account for my coldfusion hosting I have disappointed with www.crystalTech.com. I have a log full of connection time out errors and administration of their SQL Server 2005 DB is a disaster. I was even charged for a database the tech guy created just to show me how to do it. (which didn't work after all his work so I deleted it to prevent monthly charges). The straw that broke the camel's back is when I attempted to connect to my DB yesterday and everything was broken. I chatted with a tech help guy that would only respond after 5 minutes after each of my posts, and finally told me that he could log in, but taunted me by ignoring my request for the login name used on the db. (apparently it is a different name from my account login) Finally after the 3 request he disconnected from me. This has been consistent with Crystal Tech's quality of support. It is now 4:55 am in the morning and I tried to reach them. and even though they tout 24h service, no one is there. I then tried to connect to www.hostmysite.com/ and someone responded in 1 minute! Please bare with me while I switch hosting companies.

Finding my dignity!

Lately I have been accused of behaving poorly while on the playing field with my fellow team mates. I am here to set the record strait once and for all. My method of play and high level of skill is perfectly legal and ethical. I have even collaborated this with an authority none less than the USTSA! According to this fully accredited governing organization... and I quote: "Spinning the ball shall be allowed in order to influence the serve, however, no point shall be scored by the serving team unless the ball is struck by one of the serving team's figures."

That said, I have decided to rise above all my crying opponents and share the secrets of my success.(see the above photo montage.) I do this only because I know that I will always command greatness, and no doubt rise to the challenges that come from my unworthy opponents.

May the games begin!

Learning EXT JS with Coldfusion 8 and JSON Conversions

I have just recently started to learn the EXT JS Library. (www.extjs.com).
If you intend on using Coldfusion 8 with EXT JS you will find that changing a query set over to EXT JS JSON will be highly useful. I have found that doing this server side is far easier and faster than using EXT JS Readers to transform the data on the client side. A well written cfc will cost between 3-10 ms on the server side. The EXT JS readers are considerably slower and significantly more difficult to implement.
Because of web blog restrictions I had to change script to _script. You will need to change this back before you test the sample code.
========== Here is the HTML PAGE:================

<html>
    <head>
        <title>combo_Server</title>
        <!--- Get all needed ext libraries files --->
        <link rel="stylesheet" type="text/css" href="../../lib3/extjs/resources/css/ext-all.css">
        <_script src="lib/extjs/adapter/ext/ext-base.js"></script>
        <_script src="lib/extjs/ext-all-debug.js"></script>        
        <_script src="combo_server2.js"></script>
    </head>
    <body>
    </body>
</html>



============= combo_server2.js =================


/*!
* Ext JS Library 3.0.0
* Copyright(c) 2006-2009 Ext JS, LLC
* licensing@extjs.com
* http://www.extjs.com/license
*/

Ext.onReady(function(){
    

    
    //This is our JSON record set which defines what kind of data will be present in the JSON passed back from our component.
    var users = Ext.data.Record.create([
    {name:'ID',type:'int'},
    {name:'GENRE_NAME',type:'string'},
    {name:'SORT_ORDER',type:'string'}
    ])
    
// create the Data Store
var store = new Ext.data.JsonStore({
        root:'ROWS',
        url:'Chapter3Example.cfc',
        remoteSort:true,         
baseParams:{method: 'getGenres',returnFormat: 'JSON',start: '1',limit: '50'},
fields:users,
listeners: {
load:{fn: testStore},
loadexception: {fn: loadFailedReport}
}
});


// trigger the data store load
    store.load();
    
    //Display the combobox in a form panel
            new Ext.FormPanel({
            url: 'movie-form-submit.cfm',
            renderTo: document.body,
            frame: true,
            title: 'Movie Information Form',
            width: 250,
            items: [{
                xtype: 'combo',
                name: 'genre',
                fieldLabel: 'Movie Genres:',
                mode: 'local',
                store: store,
                displayField:'GENRE_NAME',
valueField: 'ID',
                width: 130,
                triggerAction: 'all',
                emptyText: 'Select a state...'
            }]
            
            
        });
    
    //This function will be called on a succesful load, it can be used for debugging or perform on load events.
    function testStore(st,recs,opts){        
console.info('Store count = ', store.getCount());
        }
        
    function loadFailedReport() {
    console.log(arguments);
    console.info("Response Text?"+response.responseText);
    console.log("dgStore Message \n"+proxy+"\n"+store+"\n"+response+"\n"+e.message);
    }         
    
});//onReady



================= The CFC to simulate the Data query set: Chapter3Example.cfc ==================



<cfcomponent output="false">
    <cffunction name="getGenres" access="remote" output="false" returntype="any" returnformat="json">
        <cfargument name="id" type="numeric" required="false" />
        <cfset var output = "" />
        <cfset var q = "" />

        <cftry>

             <cfscript>
                q = QueryNew("id,genre_name,sort_order");
                QueryAddRow(q,3);
                QuerySetCell(q,"id",1,1);
                QuerySetCell(q,"genre_name","Comedy",1);
                QuerySetCell(q,"sort_order",0,1);
                
                QuerySetCell(q,"id",2,2);
                QuerySetCell(q,"genre_name","Drama",2);
                QuerySetCell(q,"sort_order",1,2);
                
                QuerySetCell(q,"id",3,3);
                QuerySetCell(q,"genre_name","Mystery",3);
                QuerySetCell(q,"sort_order",2,3);
                
                //format the query for ExtJS json
                compObj = CreateObject("component", "CF_EXTJS");
                extjs_jsonVar = compObj.qry2json(q);
            
</cfscript>
            <cfcatch type="database">
                <cfset q="Data Set Creation Error.">
            </cfcatch>
        </cftry>

        <cfreturn extjs_jsonVar />
    </cffunction>

</cfcomponent>


=================== CFC to convert a Coldfusion query set to an EXT JS json response. ===========


<cfcomponent>
    <cffunction name="qry2json" access="public" returntype="any">
        <cfargument name="querySet" type="query" required="yes">
        <cfargument name="startRow" type="numeric" default="1" required="No">
        <cfargument name="numberOfRows" type="numeric" default="50" required="No">
        
        
        <cfset thisQueryName = arguments.querySet>
        <cfset endRow = arguments.startRow + (arguments.numberOfRows-1)>
        <cfset i = 1>
        
        <cfset thisColumnList = querySet.columnList><!---get a list of all the column names from the query--->
        <cfloop query="querySet" startrow="#arguments.startRow#" endrow="#variables.endRow#"><!---loop through each row in the record set--->        
            <cfset stcUsers = StructNew()><!---create an empty struct (clears for each loop)--->
            <cfloop index="columnName" list="#thisColumnList#" delimiters=","><!---populate the struct with the data in the row--->
                <cfset "stcUsers.#columnName#" = evaluate("querySet."&columnName)>
            </cfloop>
            <cfset arrUsers[i] = stcUsers><!---load the row data stuct into an array--->
            <cfset i = i + 1><!---increment the array counter--->            
        </cfloop>
        
        <!--- Format the JSON for EXT JS --->
        <cfset stcReturn = {rows=arrUsers,dataset=querySet.RecordCount, startRow = Arguments.startRow, endRow=numberOfRows }>        
        <cfreturn stcReturn>

    </cffunction>
</cfcomponent>


I apologize that I don't have more time to explain all the details, but I assure if you take a little time to recreate this working example, you will start to see the simplicity (and speed) of this solution.

Take care! Steven Benjamin

My First iPhone App

As I mentioned earlier, I followed along Evan Doll's 6 minute demo of the slider and the controller object. Naturally I wanted to deploy this useless app to my iPhone so I could show it to all my geek friends at bar. (While the gorgeous models looked over our shoulders waiting to get our phone numbers) When I bumped into a new error. "CodeSign error: a valid provisioning profile is required for product type 'Application' in SDK 'Device - iPhone OS 2.2.1" -Thus begins my next learning adventure. I quickly learned that you may not deploy an app to your iPhone without first registering with the Apple's iPhone Developers community. This cost $100.00 and is really quite reasonable. I am not against any of that. But that would mean I would have to wait to be accepted and then go through the whole provisioning process etc. By then the models would have moved on to the next bar and my friends and I would be out of luck. I wanted it now! So I did a little digging around and it turns out that entire provisioning cert process is handled by 2 files. a) /Developer/Platforms/iPhoneOS.platform/Info.plist b) info.plist in your app folder.

A little more blog surfing and I came across a blog that appeared to have figured it all out. That blog was on http://sanchit-tricks.blogspot.com/ which appears to have stolen the hard work of Vinod Ponmanadiyil who in my opinion deserved the bulk of the credit. Following Vinod's instructions and downloading the amazingly useful apps he recommends, I was able to install my killer slider app on my own iphone without a provisioning profile.

Also: if you are looking for some good xCode or Objective-C Videos at a really good price ($5.00) - Check out Mike Clark (I took my Ruby on Rails Class from Mike Clark and Dave Thomas) at pragmatic.tv

I am attending Stanford University ...sort of

Actually, I am really excited to tell you about Stanford University's New iphone / Objective-C Class. CS193P is being recorded and made freely available on iTunes U. More information can be found at: itunes.stanford.edu they are also exposing the class/instructors website. CS193P I am totally new to iphone development and objective-C. I am comfortable with OO Designs and I have varied experience with other C based languages. But if you have enough drive and the patients to explore these concepts, then you should consider following along with the class even without meeting these prerequisites. This is class is taught by Evan Doll, he is an engineer at Apple and graduated at Stanford in 2003. The class is also taught by Alan Cannistaro, also an Apple Engineer. I downloaded the class a couple of days ago, and the first 5 minutes of the video had bad encoding, I recently downloaded it again, and that has since been repaired. I am not sure if it was just a bad download, or if there was a server side repair made. Evan does an excellent job explaining the underlying structures of the iphone development platforms and at the end of the lesson he gives a 6 minute demo of a simple app that demonstrate how outlets are used without the need for sub classing. I wasn't sure if I was supposed to reproduce the demo, but being the curious sort, I decided to give it a try. This was my first exposure to Xcode, so it was an excellent starting point for me. I followed along, stopping the video at each step. It is also worth taking a little time to click around the Xcode IDE, Evan adjusted the view in the Library Panel to "view icons" where as mine defaulted to "view icons and descriptions", So at first glance I didn't think I was in the right window. (At first I was watching the class on my iphone, but when it came time to copy some code. The screen was too small to read the text.) During my first attempt I made a mistake that I couldn't figure out how to repair. So I downloaded his finished code example from the class site. Being a total newbe, I tried to run Evan's downloaded code and I got an error: [There is no SDK with specified name or path 'Unknown Path']. After some blog surfing, I discovered how to fix this.: In Xcode: Click on Project > Edit Project Settings > Base SDK for All Configurations: there you can select a device or a simulator. I selected Simulator - iPhone OS 2.2.1 and everything worked fine after that. I later went back reproduced the demo without error. On to the next lesson!

NetFlix NFLX

First off, I want to state that I am not a financial adviser. I am simply an individual trading my own private accounts and sharing my ideas. I encourage any feedback as I enjoy a good intellectual conversation.

That said, I am thinking that I like Netflix for fundamental reasons. With the economy on the ropes, people are looking to cut back on expenses yet they still want their nightly relaxation and entertainment. Netflix offers an excellent selection of CD's at a very affordable rate. Combined that with their newly revamped SilverStream movie delivery system over the internet and in my opinion you have a company positioned to do very well in this economy. According to the NY Times, Netflix surpassed ten million customers last February.

Netflix should be reporting quarterly earning in the next 28 days. So how can I profit from this and what if I am wrong. If I buy the stock I take on a risk of loss from the moment that I buy it. And if the projected earning are already priced in,(you know; buy the sizzle, sell the steak) then the stock will go down and I will loose money. And given that NFLX is already close to the 52 week high of $44.42 what is my potential upside?

To summarize, Now that NFLX has pulled back to the 20 day moving average and is still in a bullish stage, I think NTFX will rise to the low 40's again within the next 4 weeks. Once again,I could be wrong. So here is my play: I am going to SELL the NFLX MAY 40 Puts. I will make $420 for each contract that I sell (1 contract is 100 shares), But I will be obligated to purchase NFLX stock at the price of $40.00/share between now and the 3rd Friday of May.) This actually gives me some downside protection. At the current price of 39.68 I will have downside protection of $3.88 (almost 10% downside protection) This means that I will break even if I am forced to by the stock at 40 but it is trading at 35.80. Anything above that and I am still making a profit. Anything below that and I take a loss. From a purely statistical approach, there is a 38.58% chance that NTFX will fall below my break even during that time. My bet is that once you consider the fundamentals of this company, I am thinking that number should fall to the 25% area.

What if I am wrong? Well that is not so bad, I get NFLX stock on the cheap. (not as cheap as if I had waited and bought it in mid May, but still cheaper than today.) and since they are a profitable company, I will simpley become an Investor for a while and wait for the stock to move back up to a profitable position for me.

Finally, What if I am really really wrong. What if Bernie Madoff rented 2 million CD's and he doesn't plan to give them back. If NetFlix was to fall to zero, I would lose $3,580.00 for each contract I sold. So I am going to buy May, 30 Puts. That way if disaster hits NFLX, I would only loose $695.00 per contract. Of course I wouldn't make as much money ($420.00 - $115.00) I would make $305.00 per a contract just as long as NFLX closes above 40.00 on May 15th. 2009

One last thing to keep in mind, these are American options and I could close my positions at any time by purchasing back what I sold and selling what I bought. I frequently do this when I have hit 75% of my profit target.

Crystaltech, SQL Server 2005 and 2 Aspirin

I use Crystaltech view site for my hosting company, and aside from the slow server response about 25% of the time, they are a good hosting service. I should note that I am paying for the bottom of the rung service at about $25/month. My service includes SQL Server 2005. So I figured no problem... I will just download SQL Server Express and I am on my way! After downloading SQL Server Express 2008 and developing my databases I was ready to put it up on the server. I right click on my database and the import and export menu items are missing. I didn't realize that the express editions removed those functions. I found that CrystalTech offers a database import service for and additional $5.00. And I figured I would give it a go. The CrystalTech Import is actually a restore function that works from a .bak file. After many failed attempts I was told by the tech help team at CrystalTech that 2008 is not backward compatible to 2005. Uggg! I assumed that is would be and now I have been screwed by Microsoft again. I tried changing the compatibility level MSDN Reference to 90, but I still got the same error when I created a .bak file and attempted to restore it on SQL Server 2005. (After some more reading, I don't think that is what compatibility level is used for.) So I went on a hunt to find a full version of SQL Server Management Studio for 2005. There were also many third party utilities some worked well, others had problems with column headers, keys and identity elements. The ones that really worked were too expensive for me. Then I went looking for SQL Server 2005 Developer Edition. I found one on amazon for about $150.00 and seriously considered it. Fortunately I found Ruslan Sivak's Blog. Ruslan Sivak's Blog. (Ruslan is a fellow Coldfusion developer and also uses Ray Camden's blogCFC). As Ruslan points out there is a toolkit that installs the SQL Server import /export utility. I first installed SQL Server Management Studio Express from SQL Server 2005 Downloads. (I already had the database installed). Then I installed the SQL Server Express SP1 from SP1 Which seemed to run a completely new install. And then I went searching for: Microsoft SQL Server 2005 Express Edition Toolkit SP1 but I could not find it. Instead I download Microsoft SQL Server 2005 Express Edition Toolkit from SQL Server 2005 Downloads. And low and behold... The import / utility was exactly where Ruslan said it would be. [C:\Program Files\Microsoft SQL Server\90\DTS\Binn\DTSWizard.exe]. I followed his instructions to add the external link my SQL Studio Express and it worked perfectly. Many thanks Ruslan. Your blog post was most valuable to me.

The Westchester Co. Market Pro Computer Show: A review.

The Westchester county computer show is in town (White Plains, NY) this weekend. The Show is sponsored by Market Pro. www.marketpro.com The Westchester County Center web site (view Site) boast this: "Computer Show and sale! Up to 50% in savings. Millions in merchandise available for sale including: laptops, full computers, motherboards, monitors, hard drives, printers, CPU's memory, modems, zip drives and more!" But after I paid the $7.00 admission fee, (There is a $1.00 discount on the Market Pro Web Site)I was disappointed to find only 60-70 tables. of those tables 50-60 were computer vendors, The others where gifts, household goods and other unrelated merchandise. The show is a good place to go if you are looking to build your own custom computer from scratch. There were about 5 vendors that sold a complete line of computer components. But if you were looking to purchase a laptop or any other off the shelf product, The prices were about $30-$75 higher than most of the big name retailers in Manhattan. There was one very interesting table that sported the i9, The Chinese made copy of the iphone. This phone looks like the Apple iphone but is slightly smaller and much lighter. The phone's operating system is written entirely in Java, instead of C (actually objective-C) It is an impressive effort to say the least, but notable drawbacks are installing new applications are practically impossible and the graphical display is medium resolution. The big advantage that the iphone does have is a memory card slot. I would have bought one except it did not have a 3G to USB bridge like netPDA net PDA. If you have never seen the i9 here is a good link to view the phones. i9 Phone. This vendor also had the Chinese made copies of the ipods which were selling for $25 and looked exactly like the real thing.

Time Square Payment Center

I guess people decided to stop paying them

More Entries

BlogCFC was created by Raymond Camden. This blog is running version 5.9.2.002. Contact Blog Owner